1.4K members online now
1.4K members online now
Ask questions about Data Studio
Guide Me
star_border
Reply

Geo Map; My data contains shortened state names

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

In the data I am using to create my visuals, one column is called 'hometown' and contains a city and a state, usually shortened to 2-5 letters. If there a way to search that column with a "contains" function or something where I can determine and plot which state each person is from, despite not having the full state name? 

 

Thanks!

-Jo

1 Expert replyverified_user

Geo Map; My data contains shortened state names

Google Employee
# 2
Google Employee

Hi Jo,

 

It looks like the Region field can be used for 2-letter state names. My test also worked with "CALIF" for California, but I can't say for sure if that works for all 50 states.

 

If you need to transform the data, you can use CASE with a REGEXP_MATCH function. There are examples in the Help Center.

 

Hope this helps!

Rick