Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
I have a table on my data model with time information starting in 2022, that has estimated times for every month in for every different type of task. The columns are as follows in the dummy example:
It continues with the months until the present.
How can I extract the information of the time regarding a paricular month of a certain year for one task type?
I already have slicers for month, year and task type and I was trying the following measure:
EstimatedTime =
VAR SelectedMonth = SELECTEDVALUE('DateTable'[Month])
VAR SelectedYear = SELECTEDVALUE('DateTable'[Year])
VAR SelectedTaskType = SELECTEDVALUE('TimeTable'[TaskType])
VAR ColumnName = FORMAT(DATE(SelectedYear, SelectedMonth, 1), "dd/mm/yyyy")
RETURN
SELECTCOLUMNS(
FILTER(TimeTable, TimeTable[TaskType] = SelectedTaskType),
ColumnName )
My issue is that I am unable to pass the calculated ColumnName as a variable in SELECTCOLUMNS.
Can somebody help/suggest another approach?
Thanks in advance! ๐
Solved! Go to Solution.
Hi @Anonymous ,
@lbendlin has provided you with ideas to solve the problem. I have created an example for you based on him and you can follow the steps below:
1. You need to go to Power Query, select Task Type and then click on Unpivot other columns.
2. Add measure.
EstimatedTime =
VAR SelectedMonth =
SELECTEDVALUE ( DateTable[Month] )
VAR SelectedYear =
SELECTEDVALUE ( DateTable[Year] )
VAR SelectedTaskType =
SELECTEDVALUE ( TimeTable[Task Type] )
VAR ColumnName =
FORMAT ( DATE ( SelectedYear, SelectedMonth, 1 ), "dd/mm/yyyy" )
RETURN
SELECTCOLUMNS (
FILTER ( TimeTable, TimeTable[Task Type] = SelectedTaskType ),
"EstimatedTime", ColumnName
)
Final output:
How to Get Your Question Answered Quickly - Microsoft Fabric Community
If it does not help, please provide more details with your desired out put and pbix file without privacy information.
Best Regards,
Ada Wang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
You need to start earlier. In Power Query unpivot your data to bring it into a usable format.
Hi @Anonymous ,
@lbendlin has provided you with ideas to solve the problem. I have created an example for you based on him and you can follow the steps below:
1. You need to go to Power Query, select Task Type and then click on Unpivot other columns.
2. Add measure.
EstimatedTime =
VAR SelectedMonth =
SELECTEDVALUE ( DateTable[Month] )
VAR SelectedYear =
SELECTEDVALUE ( DateTable[Year] )
VAR SelectedTaskType =
SELECTEDVALUE ( TimeTable[Task Type] )
VAR ColumnName =
FORMAT ( DATE ( SelectedYear, SelectedMonth, 1 ), "dd/mm/yyyy" )
RETURN
SELECTCOLUMNS (
FILTER ( TimeTable, TimeTable[Task Type] = SelectedTaskType ),
"EstimatedTime", ColumnName
)
Final output:
How to Get Your Question Answered Quickly - Microsoft Fabric Community
If it does not help, please provide more details with your desired out put and pbix file without privacy information.
Best Regards,
Ada Wang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
I really should have pivoted those month columns
Thank you all for the support ๐
Check out the November 2025 Fabric update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!