Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi Experts
i am trying to write a var into the current formula using a isfilter selectedvalue statement/function, but i cannot see the error in my formula as to why i am getting "max function only accepts a column reference as an arugment".
i am trying to filter the data using the date filter...on the main dashboard.
the Report filter measure is in the Performance Measures Table.
this data in PBIX is sample and made up.
link: https://www.dropbox.com/s/jpwiwkbx973vo0d/URL_Link_Test_File_1.pbix?dl=0
Solved! Go to Solution.
Hi @Anonymous
That is because switch is expecting a true outcom and MAX and MIN return the dates.
What is that you want to achive?
ISFILTERED( 'Calendar'[Date] ) & MAX('Calendar'[Date]) & MIN('Calendar'[Date]), "?filter=" & oDate, Thanks
Mariusz
Hi @Anonymous
You need to close parenthesis in MAX function, like below.
ISFILTERED( 'Calendar'[Date] ) & MAX('Calendar'[Date]) & MIN('Calendar'[Date]), "?filter=" & oDate, Regards,
Mariusz
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi Mariusz. i just worked that out, and sorry for not spotting that. Thanks for the feedback in pointing me to the error. but when you close the Parenthesis... i get the following message now.

Hi @Anonymous
That is because switch is expecting a true outcom and MAX and MIN return the dates.
What is that you want to achive?
ISFILTERED( 'Calendar'[Date] ) & MAX('Calendar'[Date]) & MIN('Calendar'[Date]), "?filter=" & oDate, Thanks
Mariusz
Hi
i mariusz, i want the ability to filter my data using the date filter similiar to how i am using the rest of the dax formula and return the result.
thanks
HI @Anonymous ,
Your sample file seems canceled, can you please share it again? In addition, '&' character means combine left and right string. For logic 'and', 'or' operation, you need to use '&&','||'.
Regards,
Xiaoxin Sheng
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.