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
Error Message: DAX comparison operations do not support comparing values of type Date with values of type Text. Consider using the VALUE or FORMAT function to convert one of the values.
can you please help me with the same?
Solved! Go to Solution.
I have found the solution for this.
here is the piece of code in the DAX code which caused issue.
before fixing:
CALCULATETABLE(
VALUES(Sales[Customer ID]),
FILTER(
ALL(Sales),
Sales[Purchase Date] >= _DateBeforeNDays & Sales[Purchase Date] <= _EndOfMonthDate
)
)
After fixing:
CALCULATETABLE(
VALUES(Sales[Customer ID]),
FILTER(
ALL(Sales),
Sales[Purchase Date] >= _DateBeforeNDays && Sales[Purchase Date] <= _EndOfMonthDate
)
)why the error caused in the first place?
--> if you see in the first code, instead of using && operator I was just using & operator. and that was the only reason for the error.
Hi, switch does not evaluate all conditions
Good day thanks!
Sure enough, what I did was assign a number to each letter (A, B, C) in a conditional column and it worked.
I made the formula with SWITCH, but it only evaluates the first correct condition, but the others are assigned the same result of the first condition. Please if you can guide me. Thank you
@Syndicate_Admin , pls add the TOTAL CUSTOMERS column to the grid, so that its easy to evaluate your SWITCH
Hello good day
This dax throws me the error "DAX comparison operations do not support interger comparison values with Text values.Consider using the VALUE or FORMAT function to convert one of the values.
Could you help me please?
Thank you
@Syndicate_Admin in case TOTAL CUSTOMERS is a number then if you are comparing it with a String "A" which is wrong. also check the data type of TOTAL DAYS, it should be integer.
I have found the solution for this.
here is the piece of code in the DAX code which caused issue.
before fixing:
CALCULATETABLE(
VALUES(Sales[Customer ID]),
FILTER(
ALL(Sales),
Sales[Purchase Date] >= _DateBeforeNDays & Sales[Purchase Date] <= _EndOfMonthDate
)
)
After fixing:
CALCULATETABLE(
VALUES(Sales[Customer ID]),
FILTER(
ALL(Sales),
Sales[Purchase Date] >= _DateBeforeNDays && Sales[Purchase Date] <= _EndOfMonthDate
)
)why the error caused in the first place?
--> if you see in the first code, instead of using && operator I was just using & operator. and that was the only reason for the error.
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.