You need to sign in to do that
Don't have an account?
raj123
Date comparison in Soql
I have a requirement to compare the lastmodified date on access object , to the user input of no of days backs wards,
i need to find whether the lastmodifieddate is less that the user input of no of days backwards from visualforce page
what i am doing is
date d = system.today().addDays(-strNoDays);
(Select Id,last_modifieddate,Received_Date__c From Access__c where last_modifieddate >= d and received_date__c = null)
i am getting Compile Error: unexpected token: 'd' at line 459 column 324
Ay one has any ideas of doing this comparison
[Select Id,last_modifieddate,Received_Date__c From Access__c where last_modifieddate >= :d and received_date__c = null]