Forum Discussion
anvikuttu
3 years agoAdvocate I
DAX question
Hi Team, I have trouble transforming Table A to the Output Calculated Table . I wanted for every category and based on Min and Max dates, i want to generate consecutive dates between Min and Max fo...
- 3 years ago
Hey anvikuttu ,
using GENERATE and GENERATESERIES does the trick:
Table 2 = SELECTCOLUMNS( GENERATE( 'Table' , var startValue = [Min] var endValue = [Max] return GENERATESERIES( startValue , endValue , 1 ) ) , "A" , [A] , "Date" , [Value] )A screenshot:
Hopefully, this provides what you are looking for.
Nevertheless, you must consider that DAX tables will not benefit from all compressions that are happening during data load/data refresh. If the table becomes large, you might encounter performance degradation when this table is used inside measures.
Regards,Tom
Ritaf1983
3 years agoSuper User
Hi anvikuttu
You can achieve it with power query.
Please refer to attached link:
https://www.thepoweruser.com/2019/07/23/fill-dates-between-dates-with-power-bi-power-query/
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
anvikuttu
3 years agoAdvocate I
Thank you, however as mentioned in my msg i would like to do this in DAX