Forum Discussion
joshua1990
Post Prodigy
6 years agoTranslate Excel Function into Dax
Hello everybody! Is there any chance to migrate these excel functions into DAX (calculated columns)? =DATE($A2,1,1)-WEEKDAY(DATE($A2,1,1),3)+(ISOWEEKNUM(DATE($A2,1,1)-WEEKDAY(DATE($A2,1,1),3))<>1)*...
Greg_Deckler
Community Champion
6 years agoThat is correct. WEEKDAY function should operate nearly identically to WEEKDAY in Excel. Same with DATE. What is the question?
- joshua19906 years ago
Post Prodigy
How can be built that function in Dax?
WEEKDAY(DATE($A2,1,1),3)
I can't use [Year] as $A2.
How would you replicate this?
- Greg_Deckler6 years ago
Community Champion
So that depends, would need to understand your data layout. Please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490
But in general, you obviously can't use cell references with DAX, you have to filter down to the cell that you want using things like LOOKUPVALUE or MAXX(FILTER(...),...)
Things like that.