Splitting an address into multiple mappable feilds

How do i split a address into multiple mappable feilds (Ex. 123 Main Street, New York, NY, 10110 to Street, City, State and Zip as 4 mappable fields)

Watch this solution: Loom | Free Screen & Video Recording Software | Loom

2 Likes

Welcome to the Make community!

If there’s always going to be three commas separating the fields, you can use the Text Parser “Match Pattern” module with this regular expression pattern and “Global match” set to “Yes”.

(?<street>[^,]+), (?<city>[^,]+), (?<state>[^,]+), (?<zip>[^,]+)

Regex test: https://regex101.com/r/MwJBkN

Fields

Output


For more information, see Text Parser in the Make Help Center:

Match Pattern
The Match pattern module enables you to find and extract string elements matching a search pattern from a given text. The search pattern is a regular expression (aka regex or regexp), which is a sequence of characters in which each character is either a metacharacter, having a special meaning, or a regular character that has a literal meaning.

Hope this helps!