Forum Discussion
Consulta Power bi
Dear Friends, I request your support for the following case given the following table
I need the following result 1: Replicate the value on a monthly basis during the customer's term, taking into account the values in the End Date field are not the end of the month, the account is taken for the period
Result 2
In the same way, place the values on a monthly basis for the months after the END Date given a date that is set by default to the year 2035
I have done both exercises using power query creating the tables, I would like to know if it can be done via Dax to generate such a result and then place them in a bar graph
Thank you in advance
- Anonymous1 year ago
Hi, Syndicate_Admin
First, make sure your two columns are in date format as shown in the image below:
Open the Power Query Editor >> Advanced Editor in Power BI:
Enter the following code:
adddate = Table.AddColumn(changetype1,"date",each List.Dates([FECHA INICIO], Duration.Days([FECHA FIN] - [FECHA INICIO]) + 1, #duration(1, 0, 0, 0)))Expanding the date column is both the result you want:
Best Regards
Jianpeng Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
2 Replies
- AnonymousNot applicable
Hi, Syndicate_Admin
First, make sure your two columns are in date format as shown in the image below:
Open the Power Query Editor >> Advanced Editor in Power BI:
Enter the following code:
adddate = Table.AddColumn(changetype1,"date",each List.Dates([FECHA INICIO], Duration.Days([FECHA FIN] - [FECHA INICIO]) + 1, #duration(1, 0, 0, 0)))Expanding the date column is both the result you want:
Best Regards
Jianpeng Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- AnonymousNot applicable
Hi, Syndicate_Admin
I wish you all the best. Previously we have provided a solution to help you solve the problem. Since we haven't heard back from you yet, I'd like to confirm if you've successfully resolved this issue or if you need further help?
If yes, you are welcome to share your workaround and mark it as a solution so that other users can benefit as well. If you find a reply particularly helpful to you, you can also mark it as a solution.
If you still have any questions or need more support, please feel free to let us know. We are more than happy to continue to help you.
Thank you for your patience and look forward to hearing from you.Best Regards
Jianpeng Li