Need ETL formula to extract numeric ID from campaign name

KimHeinemann1113
Member
in Magic ETL
Hello - does anyone know how to write an ETL formula to extract the numeric ID at the end of this campaign name: Display_Retargeting Package_07/09/24-12/31/24_BA:4114356 so that I can get a new column with just the campaign ID (numeric string at the end of the campaign name 4114356?
Thank you so so much for any help!
0
Best Answer
-
You can either use SPLIT_PART or a regular expression:
SPLIT_PART(`field`, ':', 2)
REGEX_REPLACE(`field`, '^.*(\d+)$', '$1)
**Was this post helpful? Click Agree or Like below**
**Did this solve your problem? Accept it as a solution!**0
Answers
-
You can either use SPLIT_PART or a regular expression:
SPLIT_PART(`field`, ':', 2)
REGEX_REPLACE(`field`, '^.*(\d+)$', '$1)
**Was this post helpful? Click Agree or Like below**
**Did this solve your problem? Accept it as a solution!**0
Categories
- All Categories
- 2K Product Ideas
- 2K Ideas Exchange
- 1.6K Connect
- 1.3K Connectors
- 308 Workbench
- 7 Cloud Amplifier
- 10 Federated
- 3.8K Transform
- 661 Datasets
- 117 SQL DataFlows
- 2.2K Magic ETL
- 820 Beast Mode
- 3.3K Visualize
- 2.5K Charting
- 84 App Studio
- 46 Variables
- 781 Automate
- 193 Apps
- 483 APIs & Domo Developer
- 85 Workflows
- 23 Code Engine
- 43 AI and Machine Learning
- 22 AI Chat
- 3 AI Projects and Models
- 18 Jupyter Workspaces
- 409 Distribute
- 116 Domo Everywhere
- 282 Scheduled Reports
- 11 Software Integrations
- 146 Manage
- 142 Governance & Security
- 9 Domo Community Gallery
- 49 Product Releases
- 13 Domo University
- 5.4K Community Forums
- 41 Getting Started
- 31 Community Member Introductions
- 115 Community Announcements
- 4.8K Archive