"If not equal then"
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi
I am fairly new to Alteryx and still figuring how to use a lot of the functions.
I have a dataset with several columns.
In column A I have country codes such as AT, FR, GB, BE etc and in column B I have a code for transport method. At the moment all the transport code are 1 for all countries but I need all codes for countries other than GB to be 3. I have tried the below formula but instead of turning the 1's into 3's, it has turned them into zeroes. Could someone let me know what I have done wrong please? I have tried both MoT ans DestC as the Output column.
Thanks
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hello @BillyL14,
IF {Test} THEN {Value1} ELSE {Value2} ENDIF
You are passing a {Test} into the THEN, Alteryx will return 0 if the test is false and 1 if it's true. Simply insert "3" after the THEN.
Best Regards
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @BillyL14 if you remove [MoT]= in your formula it should work then.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi WL1,
You just need to remove "[MoT]=" from your formula.
What Alteryx is understanding at the moment is if DestC is not GB then test whether MoT equals 3 (which evaluates to false) and put that result here (thus the 0).
Hope it helps,
David
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thank you all
