Forum Discussion
Anonymous
6 years agoNot applicable
Conditional Column : If then not working
Hello , I am doing very simple If then statement using Condition column and only getting others results for all the rows. Both the columns have dataset type "Text". Does anyone why it i...
Anonymous
6 years agoNot applicable
In Excel, IF is a core function, it’s one of the first ones we learn. Last week, we looked at Functions in Power Query, but we didn’t cover a Power Query version of the IF function. Surely there is one… right? …well, kind of.
To use if logic in Power Query, we need a more programming based methodology rather than a function based methodology we find in Excel. If you’ve ever programmed VBA or other languages, you will be familiar with this approach. However, if you’re coming from a purely Excel world this may be new to you.
There are two options:
Using the conditional column feature for basic if logic
Writing M code for more advanced if logic.
Admin