Forum Discussion

Ghaston's avatar
Ghaston
Helper I
7 years ago
Solved

problem with filtring

hi 
i'm using Direct Qid_uery and i'm having a hard time filtring my date with "CALCULATE" function. 
I have a Column "ID_OF", and i want to run the result juste for the highest value of "ID_OF". 
So i created this mesure : 

But it didn't work. I get the result for all "ID_OF" and not the max as i wanted. 
So i put the "last_OF" variable, in a mesure : 

And this mesure gave me the max value of "ID_OF" as planned. Wich is 12198 in this case. 

But i don't understand why it didn't work on my first formula? i changed the variable "Last_OF" with the mesure that i have just created "Last_OF", but nothing changes. 
However, i get the result that i'm expecting when i replace 'Last_OF" by it's value :12198. 


Need help please

  • Anonymous's avatar
    Anonymous
    7 years ago

    Hi Ghaston,

     

    Actually when you were calculating last_of in your variable that is dynamic and you provide a scenario where you are fixing a fixed value like 12198.

    So in variable also you have to do same, by filtering all table data.

     

     

     

    Hope this will solve your problem. i have also sent you pbix file.

     

    Best Regards,

    Ravi

6 Replies