Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago

Subtracting a date from today

I am trying to find the number of days from a date field to today and have searched the posts but cannot find what I need.  When I use datediff e.g. - Note: I have to use DirectQuery mode.

 

DATEDIFF (table.field, today(), DAY) I get:

 

Error Message:
OLE DB or ODBC error: [Expression.Error] Local evaluation of Table.Join or Table.NestedJoin with key equality comparers is not supported..

 

I have also tried DATEVALUE subtract but still get the same error

 

It has been suggested that the underlying field is a datetime and that is why it is not working, but I did change the datetime to a short date in the editor, but still no joy.

 

Can anyone suggest anything else