March 31, 200916 yr I would like to have a field that shows 1 if the date field is at or prior to 1/1/09 and 0 if the date is after 1/1/09. Thank you
March 31, 200916 yr Case (Date < "1/1/2009"; 1; Date > "1/1/2009"; 0) Assuming you don't want 1/1/2009 included. If you want 1/1/2009 to calculate as 0: Case (Date < "1/1/2009"; 1; Date ≥ "1/1/2009"; 0) If you want 1/1/2009 to calculate as 1: Case (Date ≤ "1/1/2009"; 1; Date > "1/1/2009"; 0)
March 31, 200916 yr Case (Date < "1/1/2009"; 1; Date > "1/1/2009"; 0) Assuming you don't want 1/1/2009 included. If you want 1/1/2009 to calculate as 0: Case (Date < "1/1/2009"; 1; Date ≥ "1/1/2009"; 0) If you want 1/1/2009 to calculate as 1: Case (Date ≤ "1/1/2009"; 1; Date > "1/1/2009"; 0) This wont work.
March 31, 200916 yr Thanks John. I always use the GetAsDate() function, but always forget to include it in my replies.
March 31, 200916 yr I NEVER use the GetAsDate() function to specify a date, because it relies on the local date format: YourDate ≤ Date ( 1 ; 1 ; 2009 )
March 31, 200916 yr Still working that one into my memory banks. That's the problem with self-taught strategies. Bad habits. Thanks comment.
Create an account or sign in to comment