Help

Upcoming database upgrades. Airtable functionality will be reduced for ~15 minutes at 06:00 UTC on Feb. 4 / 10:00 pm PT on Feb. 3. Learn more here

Regex to extract 1, 2 or 3 digit number after character

Solved
Jump to Solution
145 2
cancel
Showing results for 
Search instead for 
Did you mean: 

Hello, I’m trying to extract the final number at the end of a string like this:

Josh-B7-3
Ben-B8-28
Chris-BN-294

I want to extract just:
3
28
294

Any ideas? Appreciate your time :slightly_smiling_face:

1 Solution

Accepted Solutions

Try this. It features the $ control character for matching the end of a string that I recently talked about in the BuildOnAir podcast.

REGEX_EXTRACT(
    {field name},
    "\d*$"
)

See Solution in Thread

2 Replies 2

Try this. It features the $ control character for matching the end of a string that I recently talked about in the BuildOnAir podcast.

REGEX_EXTRACT(
    {field name},
    "\d*$"
)

Thanks so much @kuovonne