extract domain in beast move
Best Answers
-
Hello @MReznick,
Sadly there is not an effective way to accomplish this through a beastmode. However we can accomplish this through a SQL dataflow.
To do this we are going to take advantage of the SQL function SUBSTRING_INDEX().
For example:
Email: test.user@domain.comSUBSTRING_INDEX('test.user@domain.com','@',-1) --> domain.com
If you would like to remove the ".com" we can remove this by adding another SUBSTRING_INDEX() to the query.
SUBSTRING_INDEX(SUBSTRING_INDEX('test.user@domain.com','@',-1),'.',1) ---> domain
Here is a great link to a resource that explains how SUBSTRING_INDEX() works further.
http://www.w3resource.com/mysql/string-functions/mysql-substring_index-function.php
If you have any further questions in regards to this, you can email Domo support at support@domo.com. A support tech will be able to help answer any additional questions you may have.**Say “Thanks" by clicking the thumbs up in the post that helped you.
**Please mark the post that solves your problem by clicking on "Accept as Solution"1 -
Obviously very late but this is how I do it:
RIGHT(`Email Address`,((LENGTH(`Email Address`))-(INSTR(`Email Address`,'@'))))
3
Answers
-
Similar question was posted in the Dojo recently... I posted the following (link) suggestion related to doing it in DataFlow, but the same might work in BeastMode. I have found that MySQL functions will work in Beast Mode even though they are not reflected as part of the Beast Mode function list.
Extract Domain from Email Address
Good luck, please let me know if that works or not.
**Say thank you by clicking the 'thumbs up'
**Be sure to select the answer that represents the best solution and mark as "Accept as Solution"0 -
No, that locate is not a function in beast mode and I cannot find a similar funtion
0 -
Hello @MReznick,
Sadly there is not an effective way to accomplish this through a beastmode. However we can accomplish this through a SQL dataflow.
To do this we are going to take advantage of the SQL function SUBSTRING_INDEX().
For example:
Email: test.user@domain.comSUBSTRING_INDEX('test.user@domain.com','@',-1) --> domain.com
If you would like to remove the ".com" we can remove this by adding another SUBSTRING_INDEX() to the query.
SUBSTRING_INDEX(SUBSTRING_INDEX('test.user@domain.com','@',-1),'.',1) ---> domain
Here is a great link to a resource that explains how SUBSTRING_INDEX() works further.
http://www.w3resource.com/mysql/string-functions/mysql-substring_index-function.php
If you have any further questions in regards to this, you can email Domo support at support@domo.com. A support tech will be able to help answer any additional questions you may have.**Say “Thanks" by clicking the thumbs up in the post that helped you.
**Please mark the post that solves your problem by clicking on "Accept as Solution"1 -
I really don't wat to run my data through a flow just to be able extract the domain in a card.
0 -
Obviously very late but this is how I do it:
RIGHT(`Email Address`,((LENGTH(`Email Address`))-(INSTR(`Email Address`,'@'))))
3
Categories
- All Categories
- 1.8K Product Ideas
- 1.8K Ideas Exchange
- 1.6K Connect
- 1.2K Connectors
- 300 Workbench
- 6 Cloud Amplifier
- 9 Federated
- 2.9K Transform
- 102 SQL DataFlows
- 626 Datasets
- 2.2K Magic ETL
- 3.9K Visualize
- 2.5K Charting
- 754 Beast Mode
- 61 App Studio
- 41 Variables
- 693 Automate
- 178 Apps
- 456 APIs & Domo Developer
- 49 Workflows
- 10 DomoAI
- 38 Predict
- 16 Jupyter Workspaces
- 22 R & Python Tiles
- 398 Distribute
- 115 Domo Everywhere
- 276 Scheduled Reports
- 7 Software Integrations
- 130 Manage
- 127 Governance & Security
- 8 Domo Community Gallery
- 38 Product Releases
- 11 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 110 Community Announcements
- 4.8K Archive