Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello
I need to create a table that contains the numbers 0 to n based on the number of months I have in my tables
I can use
= List.Numbers(0, 20)
to create my list
,but I want the number of rows to be dependent on a minimum and maximum dates in another table. So, for example. If the minumum date in a column is 1/1/2022, and the maximum date in a different column is 1/7/2022, that's 7 months so I want 7 rows showing the numbers 0 to 6.
Is there a way to do this? I've tried using parameters to get the min and max date, but that doesn't seem to work.
Many thanks.
Solved! Go to Solution.
I think I have worked it out using = List.Numbers(0,List.Max(claims[ClosedDevMo])+1)
I think I have worked it out using = List.Numbers(0,List.Max(claims[ClosedDevMo])+1)
Actually, change that slightly, forget about dates. I have a column in my containing the month number, I just need to create a table that goes from 0 to the max of that column value.
User | Count |
---|---|
70 | |
70 | |
34 | |
23 | |
22 |
User | Count |
---|---|
96 | |
94 | |
50 | |
42 | |
40 |