Any way to get text value from one column based on text value of another column?
I've got a data set that is a series of user and assistant responses. I'm trying to build a table visualization that will show me all user questions where the assistant did not have an answer.
My thought was that I could search for the default “no answer” response in the assistant response columns, but am stuck at how to then return the user question that prompted the “no answer response" as a value that I can display in a table.
I was attepting to use
CASE WHEN DP DP Response 2
= ‘DP: Sorry, I don't have an answer for that.’
THEN User Question 2
END
but kept getting syntax errors and not sure if that's just not possible w/ text or if I've missed something completely. Also realize I may not be able to use the full text due to the use of apostrophe so will likely need to try to search by contains ‘DP: Sorry’ but Beast Mode doesn't seem to recognize CONTAINS?
Screenshot of one of these occurences within the data attached. Help?
Best Answer
Answers
-
@MichelleH that did help with the syntax error, but somehow I'm getting no data returned with that formula as a whole. Do you know if I'm missing something that would actually pull through the value of the “User Question 2” column?
0 -
@aarguijo Does it still return no values if you change it to this?
case when DP Response 2 LIKE ‘DP: Sorry%’ then 1 end
If you see 1s populating, then that means there's not data in the User Question 2 field. If not then there's something wrong with the condition, for example there are extra spaces in the string you're searching
1 -
Ah I figured it out. It wanted a % at the start of the string as well - so
case when DP Response 2 LIKE ‘%DP: Sorry%’ then User Question 2 end
Thanks so much for your help!
0
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
- 101 SQL DataFlows
- 622 Datasets
- 2.2K Magic ETL
- 3.9K Visualize
- 2.5K Charting
- 747 Beast Mode
- 59 App Studio
- 41 Variables
- 686 Automate
- 176 Apps
- 453 APIs & Domo Developer
- 47 Workflows
- 10 DomoAI
- 36 Predict
- 15 Jupyter Workspaces
- 21 R & Python Tiles
- 396 Distribute
- 113 Domo Everywhere
- 276 Scheduled Reports
- 7 Software Integrations
- 126 Manage
- 123 Governance & Security
- 8 Domo Community Gallery
- 38 Product Releases
- 10 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 109 Community Announcements
- 4.8K Archive