Forum Discussion
DAX to Power Query - IF Statement
- 2 years ago
PowerUser39 OK, I don't get any errors and just one difference, is this what you are seeing as well? One thing is that I don't quite understand your DAX, you seem to have a useless IF statement in there as it returns the same thing regardless (line 4). Also, be careful with using "" as you might want to change this to null in PQ. PBIX is attached.
PowerUser39 I'm guessing that your errors are coming from comparing datetime to number or something else related to datetime. Can you provide sample data so I can put this into a PBIX file and test?
- PowerUser392 years agoFrequent Visitor
Sure it is a huge dataset but it looks similar to below
TEST1 TEST2 TEST3 TEST4 2020 2020 2020 2020 5 2023 2018 2013 5 2022 2018 2005 2022 2005 5 2020 2017 2009 6 - Greg_Deckler2 years agoCommunity Champion
PowerUser39 OK, I don't get any errors and just one difference, is this what you are seeing as well? One thing is that I don't quite understand your DAX, you seem to have a useless IF statement in there as it returns the same thing regardless (line 4). Also, be careful with using "" as you might want to change this to null in PQ. PBIX is attached.
- PowerUser392 years agoFrequent Visitor
Thanks Greg. I inserted another condition to exclude the Null value and it worked for me.