function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
RArunrajRArunraj 

Compare Date time field in List view Filter condition

Hi

 

Can any body help me, How to compare Date time field in List view Filter condition.

 

For ex:

 

Transaction Date/Time (Custom Field)  less than or equal  NOW

 

I am getting error as  Invalid date (Valid date format 10/5/2011 or 10/5/2011 9:42 AM)

 

Thanks,


Best Answer chosen by Admin (Salesforce Developers) 
sfdcfoxsfdcfox

Use only the list of approved date filters found here:

 

https://help.salesforce.com/apex/HTViewHelpDoc?id=custom_dates.htm&language=en

 

There are no "date/time" literals, only date literals. You can't specify NOW, but you could specify TODAY.

 

If you need up-to-the-minute decision making, use a formula, such as:

IF(MyDateTimeField__c<NOW(),"Time Up","Time Left")

 

 

All Answers

sfdcfoxsfdcfox

Use only the list of approved date filters found here:

 

https://help.salesforce.com/apex/HTViewHelpDoc?id=custom_dates.htm&language=en

 

There are no "date/time" literals, only date literals. You can't specify NOW, but you could specify TODAY.

 

If you need up-to-the-minute decision making, use a formula, such as:

IF(MyDateTimeField__c<NOW(),"Time Up","Time Left")

 

 

This was selected as the best answer
Sathwick SivvalaSathwick Sivvala
This works. Thanks.