This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreLevel up your Power BI skills this month - build one visual each week and tell better stories with data! Get started
Hello people,
I need help!
I have a spreadsheet in .xls with some data as below that shows allocated people in some tasks:
| Name | Start date | End date | Hours per day |
| Resource 1 | 01-01-2021 | 01-04-2021 | 2 |
| Resource 2 | 04-01-2021 | 04-03-2021 | 4 |
I need to show this data in a table like this:
| Name | Date | Hours per day |
| Resource 1 | 01-01-2021 | 2 |
| Resource 1 | 01-02-2021 | 2 |
| Resource 1 | 01-03-2021 | 2 |
| Resource 1 | 01-04-2021 | 2 |
| Resource 2 | 04-01-2021 | 4 |
| Resource 2 | 04-02-2021 | 4 |
| Resource 2 | 04-03-2021 | 4 |
I've tried some ways but I was not able to solve this problem.
Please, someone, have any idea how to solve this problem?
Thank you!
Solved! Go to Solution.
@Anonymous,
Create a disconnected date table (no relationships):
Create the measures below. The second measure is necessary to calculate totals.
Base measure:
Daily Hours Calc =
VAR vDate =
MAX ( DimDate[Date] )
VAR vResult =
IF (
vDate >= MAX ( FactTable[Start date] )
&& vDate <= MAX ( FactTable[End date] ),
MAX ( FactTable[Hours per day] )
)
RETURN
vResult
Totals measure:
Daily Hours =
VAR vTable =
ADDCOLUMNS (
CROSSJOIN ( VALUES ( FactTable[Name] ), VALUES ( DimDate[Date] ) ),
"@Hours", [Daily Hours Calc]
)
VAR vResult =
SUMX ( vTable, [@Hours] )
RETURN
vResult
Create matrix:
If you add the Name and Date fields first, you will get the error below. However, once you add the measure, the error will resolve. You can avoid this error by adding the measure first.
Proud to be a Super User!
@Anonymous,
Create a disconnected date table (no relationships):
Create the measures below. The second measure is necessary to calculate totals.
Base measure:
Daily Hours Calc =
VAR vDate =
MAX ( DimDate[Date] )
VAR vResult =
IF (
vDate >= MAX ( FactTable[Start date] )
&& vDate <= MAX ( FactTable[End date] ),
MAX ( FactTable[Hours per day] )
)
RETURN
vResult
Totals measure:
Daily Hours =
VAR vTable =
ADDCOLUMNS (
CROSSJOIN ( VALUES ( FactTable[Name] ), VALUES ( DimDate[Date] ) ),
"@Hours", [Daily Hours Calc]
)
VAR vResult =
SUMX ( vTable, [@Hours] )
RETURN
vResult
Create matrix:
If you add the Name and Date fields first, you will get the error below. However, once you add the measure, the error will resolve. You can avoid this error by adding the measure first.
Proud to be a Super User!
Check out the April 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 31 | |
| 25 | |
| 21 | |
| 18 | |
| 17 |
| User | Count |
|---|---|
| 62 | |
| 34 | |
| 33 | |
| 25 | |
| 24 |