SOLVED
RegEx extract numbers before and after text string
Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
EJ_Alt
7 - Meteor
‎08-27-2022
10:10 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi All,
I would appreciate some help with using a RegEx or suitable tool to do this. Essentially extract all digits before and after text
Account ID | ID 1 | ID2 | ID3 |
1234D983.22 | 1234 | D | 983.22 |
12N4445.56 | 12 | N | 4445.56 |
4Z33.33 | 4 | Z | 33.33 |
Thanks
Solved! Go to Solution.
Labels:
- Labels:
- Regex
5 REPLIES 5
17 - Castor
‎08-27-2022
10:19 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hey @EJ_Alt,
Here is one way to do this with Regex
([\d\.]+)(\D+)([\d\.]+)
The first and third group captures one or more number characters or points '.':
([\d\.]+)
The second group captures any non number characters:
(\D+)
If you want to learn more about Regex the community has some really quick interactive videos on getting to grips with it here https://community.alteryx.com/t5/Interactive-Lessons/tkb-p/interactive-lessons/label-name/Parsing%20...
Any questions or issues please ask
Ira Watt
Technical Consultant
Watt@Bulien.com
binuacs
21 - Polaris
‎08-27-2022
03:24 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Alteryx_AR
12 - Quasar
‎08-27-2022
07:07 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
‎08-28-2022
02:48 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thanks!
‎08-28-2022
02:49 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thanks! works too.
