Hi @IsmaelChivite & Experts
I would like to include in between the date from and to and I have Applied a logic by going through your idea but it fails when i choose 27th feb 2026 then spring should be populated but it is considering winter
I have attached the XLS, Need Guidance how to correct or what i missed
I shall be thankful
Winter | Winter | From 11 Nov to 19 Feb. |
Spring | Spring | From 20 Feb. to 20 May |
Summer | Summer | From 21 May to 14 Aug |
Autumn | Autumn | From 15 Aug. to 10 Nov |
Solved! Go to Solution.
Your calculation is based on the month, but the value you are using is month + day. 427 is greater than 11, so that is why you are getting Winter.
Also, the order of your if statements matter. Survey will stop at the very first statement that is true. If todays_monthday is equal to 6, it will return Spring because 6 is greater than 2 so it stops checking the rest of the calculation. It doesn't even know there is an option to check and see if it is greater than 5.
if(${todays_monthday}>11,'Winter',if(${todays_monthday}>2,'Spring',if(${todays_monthday}>5,'Summer',if(${todays_monthday}>6,'Spring','Winter'))))
With those things in mind, the following should work for what you want.
if(${todays_monthday}>1111,'Winter',if(${todays_monthday}>815,'Autumn',if(${todays_monthday}>521,'Summer',if(${todays_monthday}>220,'Spring','Winter'))))
Your calculation is based on the month, but the value you are using is month + day. 427 is greater than 11, so that is why you are getting Winter.
Also, the order of your if statements matter. Survey will stop at the very first statement that is true. If todays_monthday is equal to 6, it will return Spring because 6 is greater than 2 so it stops checking the rest of the calculation. It doesn't even know there is an option to check and see if it is greater than 5.
if(${todays_monthday}>11,'Winter',if(${todays_monthday}>2,'Spring',if(${todays_monthday}>5,'Summer',if(${todays_monthday}>6,'Spring','Winter'))))
With those things in mind, the following should work for what you want.
if(${todays_monthday}>1111,'Winter',if(${todays_monthday}>815,'Autumn',if(${todays_monthday}>521,'Summer',if(${todays_monthday}>220,'Spring','Winter'))))
@JenniferAcunto
Thank for your response