Forum Discussion
To display repeated rows using DAX
- 9 years ago
Hi Sakshi,
Based on my test, you should be able to follow steps below to get your expected result in Power BI. :smileyhappy:
1. In Query Editor, use the formula(M) below to add a new custom column called "End-Date" under Add Column tab > Custom Column.
= Date.AddDays([#"Start-Date"],[No. of Repeating days]-1)
2. Use the formula(M) below to add another custom column called "Date".
= {Number.From([#"Start-Date"])..Number.From([#"End-Date"])}3. Expand to New Rows for Date column.
Then you will get a table like below.
4. Last, you will get your expected result by changing Data Type to Date for "Date" column.
5. Click "Close&Apply" to apply the changes.
Regards
Hi Sakshi,
Based on my test, you should be able to follow steps below to get your expected result in Power BI. :smileyhappy:
1. In Query Editor, use the formula(M) below to add a new custom column called "End-Date" under Add Column tab > Custom Column.
= Date.AddDays([#"Start-Date"],[No. of Repeating days]-1)
2. Use the formula(M) below to add another custom column called "Date".
= {Number.From([#"Start-Date"])..Number.From([#"End-Date"])}
3. Expand to New Rows for Date column.
Then you will get a table like below.
4. Last, you will get your expected result by changing Data Type to Date for "Date" column.
5. Click "Close&Apply" to apply the changes.
Regards