Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I'm trying to do some logic in the Data Prep tool with if then else, but I do not see how.
IF [dataset_a].[column_3] = "Dorothy" AND [dataset_a].[column_4] = "Wizard of Oz" THEN "Rainbow"
ELSE LOOKUP [dataset_a].[column_7] AGAINST [dataset_b].[column_1] RETURN [dataset_b].[column_5]
I can do the lookup fine, but how do I do the if this and that then else logic?
If I have to go outside of the tool then the tool will not do. I do not want to write a Talend job with tMap logic.
Thanks,
Myles
Hi Myles,
There is no direct if/then/else functions in Data Prep... but you can play with filters to get this logic. You can filter on a dedicated value and retain the dataset against this value with functions like "Keep these filtered rows" for example. See the attached screenshot.
Regards,
Patrick
Hi Myles,
There is no direct if/then/else functions in Data Prep... but you can play with filters to get this logic. You can filter on a dedicated value and retain the dataset against this value with functions like "Keep these filtered rows" for example. See the attached screenshot.
Regards,
Patrick
Thanks Patrick. I saw the filtering example in a how to, but I want to keep the all the data.
- Myles
And by the way, there is a dedicated topic in the online doc for that: https://help.talend.com/reader/stPif1ZSGQHZQ88m_d19mg/TxjabS_sKBjXRebpg78YHA
Cheers,
Patrick