CRM and GetDate()
Posted: Wed 06 Apr 2022 15:57
Is it possible to use getdate() or similar to get recently updated records (rather than pulling full dataset).
Example being:
(OpenQuery used for performance, rather than pulling the full table to the local SQL server.)
This returns this error message which implies that the function getdate() is not implemented:
In theory could build up the SQL and then use EXECUTE to get the data, however this is very messy - getdate() is simpler.
Example being:
Code: Select all
SELECT * FROM OPENQUERY(CRM,'SELECT * FROM quotedetail WHERE createdon >= getdate()-14') CRM
This returns this error message which implies that the function getdate() is not implemented:
Code: Select all
SQL.sql: OLE DB provider "MSDASQL" for linked server "CRM" returned message "[Devart][ODBC][Dynamics 365]SQLite error
no such function: getdate".
SQL.sql: Error (9,1): Cannot get the column information from OLE DB provider "MSDASQL" for linked server "CRM".