+ Start a Discussion
Andrew Hoban 6Andrew Hoban 6 

Formula field depending on date range

HI,

Im looking to reate a formula text field that will bring back either 'Yes' or 'No' depending on a date range. If the date falls between 25/15/2105 and 10/05/2016 then it should bring back Yes.

Thanks
claperclaper
create a formula field with return type of Text.
Enter this as the formula:
IF(your_custom_field__c >= DATE(2015,2,15) && your_custom_field__c <= DATE(2016,10,05), "Yes", "No")

 
Arun KumarArun Kumar
Hi Andrew,

Try below code
IF(
AND(DATE(2015,12,25)<=TODAY(),
TODAY()<= DATE(2016,05,10)),
'Yes',
'No')
Replace TODAY() with [Your Date].

Thanks,
Arun

 
Sudipta DebSudipta Deb
Hi Andrew,

You can use this formula field -
IF( sudipta__My_Date__c >= DATE(2015,05,25) && sudipta__My_Date__c <= DATE(2016,05,10) , 'Yes', 'No')
Thanks,
Sudipta Deb