Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello,
Solved! Go to Solution.
https://community.powerbi.com/t5/Community-Blog/Excel-to-DAX-Translation/ba-p/1060991
The DAX functions are identical to the Excel functions in your case, so:
Column =
IF(ISNUMBER([Column K]),
[Column K] - [Column J],
IF([Column J] > TODAY(),
"",
TODAY() - [Column J]
)
)
@Anonymous , if J is number that it can not be compared with today and if it is then you need to return same type data
try like
Column =
IF(isnumber([Column K]),
[Column K] - [Column J],
IF([Column J] > TODAY(),
blank(),
datediff(TODAY() , [Column J], day)
)
)
@amitchandak thank you , Its good to know that I can use excel funtion on power BI, but I am getting an error both my date colunms are formatted to date. Not sure why is that. Any Idea?
Not sure what this is translating to spanish. hopefully you can see it english
@Anonymous
please try this
Column = if(ISNUMBER('Table'[record date]),'Table'[record date]-'Table'[date],if('Table'[date]>today(),blank(),today()-'Table'[date]))
Proud to be a Super User!
@ryan_mayu Thank you, but I am getting error. Please see below if you know anything
https://community.powerbi.com/t5/Community-Blog/Excel-to-DAX-Translation/ba-p/1060991
The DAX functions are identical to the Excel functions in your case, so:
Column =
IF(ISNUMBER([Column K]),
[Column K] - [Column J],
IF([Column J] > TODAY(),
"",
TODAY() - [Column J]
)
)
@Greg_Deckler Good to know that I can use excel funtion, but i ma getting an error when I do that. (Both my Due Date and Actual Delivary Date are on Date format). I am not sure what is variant-type cannot be used. Any idea? Thank you
@Anonymous - Yes, you will need to either always return text or numbers. You formula returns text sometimes and numbers other times, that is not allowed in DAX. So you can either replace your "Other" with 0 or some other number.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
115 | |
99 | |
86 | |
70 | |
62 |
User | Count |
---|---|
151 | |
120 | |
103 | |
87 | |
68 |