Forum Discussion
Help for using start date and end date issues
- 6 years ago
Anonymous , not very clear to me. Check if this blog can help. It deals will start date end date and active between
Hi there,
Yes, what you want to accomplish is doable in Power BI. However, you are showing a screenshot of Excel?!? I'm new here as well and while I believe you can start Excel, I've always started in Power BI. Please confirm you have Power BI.
Essentially, you will need to create two tables. One has all dates for the next few years and the product names:
Transactional Date Hierarcy = var _calendar = CALENDAR("1/1/2020","12/31/2025") return addcolumns(_calendar, "Today", Today(), "Product Name", allselected([PRODUCT NAME COLUMN]))
I'm not 100% on the syntax for getting the product name, but I think this is a good starting point.
The other table to add would be your Excel table.
Add a relationship (far left icons) from the calendar table to your excel table by product name. Excel should filter the calendar. You would then create new measures (Table->New Measure) on the calendar table that helps to determine the "total" value for any given day.
Finally, you will then add a visualization (Insert->New Visual) and change that visual to a matrix under Visualizations.
Under Rows select Category.
Under Columns select Date (there will be a date hierachy in the table, best to use that column).
Under Values select whatever calculation you want to show from the calendar.
You can add filters to this visualization for the start and end date.
Sorry it is not a bit more detail. Hope it helps...