You need to sign in to do that
Don't have an account?
ccrawford07
Comparing datetime fields in SOQL
Hello,
I'm trying to do a query like this:
But I get an error:
How can I do a quick date comparison in SOQL?
Thanks!
I'm trying to do a query like this:
Code:
SELECT Id, LastModifiedDate, Name, updatedDate__c FROM Account WHERE LastModifiedDate > updatedDate__c
Code:
ERROR at Row:1:Column:89 unexpected token: updatedDate__c
How can I do a quick date comparison in SOQL?
Thanks!
You can create a formula field that calcs the difference between your 2 dates, and use that in your query instead.