AnsweredAssumed Answered

Check if date between two dates

Question asked by Emmanuel on Jul 3, 2014
Latest reply on Jul 3, 2014 by Emmanuel

Title

Check if date between two dates

Post

     Hi,

     I got this calculated field:

     Case ( 
      
     Date (8;1;CurrentYear) ≤ _date inscription  ≤ Date (7;31;CurrentYear+1) ; CurrentYear &"-"& CurrentYear+1 ;
      
     Date (8;1;CurrentYear-1) ≤ _date inscription  ≤ Date (7;31;CurrentYear) ; CurrentYear-1 &"-"& CurrentYear ;
      
     Date (8;1;CurrentYear-2) ≤ _date inscription  ≤ Date (7;31;CurrentYear-1) ; CurrentYear-2 &"-"& CurrentYear-1 ;
      
     Date (8;1;CurrentYear-3) ≤ _date inscription  ≤ Date (7;31;CurrentYear-2) ; CurrentYear-3 &"-"& CurrentYear-2 ;
      
     Date (8;1;CurrentYear-4) ≤ _date inscription  ≤ Date (7;31;CurrentYear-3) ; CurrentYear-4 &"-"& CurrentYear-3 ;
      
     Date (8;1;CurrentYear-5) ≤ _date inscription  ≤ Date (7;31;CurrentYear-4) ; CurrentYear-5 &"-"& CurrentYear-4 ;
      
     )

      

     But the results are always the first line of the case even though it should be 2010-2011 or whatever.

     What is it that goes wrong?

      

     Note Current year  = Year ( Get (CurrentDate)) >> Global field

      

     Thank you

Outcomes