Forum Discussion
Error "comparing values integer with text"
- 5 years ago
Hi,
The issue was somehow connceted to the the [Sales Total]. The measure was producing a result, but it had an underlying LOOKUPVALUES -reference that was broken. Quite honestly it seems like a bug to have the measure working in one place but not at another. Never the less, solved.
Hi CarlsBerg999
I'd advice you to comment out you filter statements, one at a time to find the one that is producing the error:
RANKX (
'Table3',
CALCULATE (
[Sales Total],
// DateTable[Year] = YEAR ( TODAY () ),
'Table1'[Task Status] <> "Stopped",
'Table2[Status] <> "Cancelled",
ALLEXCEPT ('Table3', 'Visuals Customer'[Customer ID] )
),
,
DESC
)
If the measure works you move onto the next filter statement and eventually you should be able to determine which statement is porducing the error.
Br,
J
Hi, i tried this and the error left when i got to the statement:
ALLEXCEPT ('Table3', 'Table3'[Customer ID] )However, i don't understand why this is causing a problem. This doesn't really "compare" Customer ID with any data. It just removes filters.
- tex6285 years agoCommunity Champion
That is indeed quite strange. If you try and move the calculate statment out of the rankx statement, do you still encounter issues?
Measure = CALCULATE ( [Sales Total], DateTable[Year] = YEAR ( TODAY () ), 'Table1'[Task Status] <> "Stopped", 'Table2[Status] <> "Cancelled", ALLEXCEPT ('Table3', 'Visuals Customer'[Customer ID] ) )- tex6285 years agoCommunity Champion
Try moving the ALLEXCEPT statment out to the RANKX statement:
RANKX ( ALLEXCEPT ('Table3', 'Table3'[Customer ID] ) CALCULATE ( [Sales Total], DateTable[Year] = YEAR ( TODAY () ), 'Table1'[Task Status] <> "Stopped", 'Table2[Status] <> "Cancelled" ), , DESC )- CarlsBerg9995 years agoHelper V
Hi,
The issue was somehow connceted to the the [Sales Total]. The measure was producing a result, but it had an underlying LOOKUPVALUES -reference that was broken. Quite honestly it seems like a bug to have the measure working in one place but not at another. Never the less, solved.