Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello,
Need help dax formula or else.
My query that I wanted are, create a table to generate dates per each attribute.
From Month as start date to End Date
Each attributes needs a start to end dates in a separate table.
Exmp.
RES 01/01/2020 475
RES 01/02/2020 475
...
..
RES 01/31/2020 475
ENTERPRIZE ELITE 01/01/2020 1022
ENTERPRIZE ELITE 01/02/2020 1022
..
..
ENTERPRIZE ELITE 01/31/2020 1022
Big help for me.
Hi, @Anonymous , I prefer Power Query to DAX in terms of such data transformation. You may want to follow this pattern.
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjIwMtA1MAQiJR2lINdgBVcPFyDLxNwUSMIkjQ2VYnXQ1LrmlaQWFRRlFqcquOZklqQChQwNjIzQdMUCAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [StartDate = _t, Attribute = _t, Value = _t, EndDate = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"StartDate", type date}, {"Attribute", type text}, {"Value", Int64.Type}, {"EndDate", type date}}),
#"Added Custom" = Table.AddColumn(#"Changed Type", "Custom", each List.Dates([StartDate], Duration.Days([EndDate]-[StartDate])+1, #duration(1,0,0,0))),
#"Expanded Custom" = Table.ExpandListColumn(#"Added Custom", "Custom")
in
#"Expanded Custom"| Thanks to the great efforts by MS engineers to simplify syntax of DAX! Most beginners are SUCCESSFULLY MISLED to think that they could easily master DAX; but it turns out that the intricacy of the most frequently used RANKX() is still way beyond their comprehension! |
DAX is simple, but NOT EASY! |
@CNENFRNL
Thanks for your code, however I just copy paste your codes.
And I'm having an error on "Added Custom". I dont know if I'm getting the right list.date
THanks for having this
Hi, @Anonymous , there are some glithes in your code; pls change them like this,
#"Added Custom" = Table.AddColumn(#"Changed Type", "Custom", each List.Dates([StartDate], Duration.Days(Date.EndOfMonth([StartDate])-[StartDate])+1, #duration(1,0,0,0))),
| Thanks to the great efforts by MS engineers to simplify syntax of DAX! Most beginners are SUCCESSFULLY MISLED to think that they could easily master DAX; but it turns out that the intricacy of the most frequently used RANKX() is still way beyond their comprehension! |
DAX is simple, but NOT EASY! |
Can I used that your query? may I know how I can edit the table you created?.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 8 | |
| 6 | |
| 6 | |
| 5 | |
| 4 |
| User | Count |
|---|---|
| 25 | |
| 14 | |
| 8 | |
| 8 | |
| 8 |