hi I am trying to test null values for a DAteformula type field in an IF condition, but am not able to do it. Can anyone tell me how. Eg IF Field1 = ‘’ THEN Regards
hi, u can declare a text variable and put the value as text in that variable. Then check the ‘’ in text vairable. e.g. Text1 := format(filed1); if text1 = ‘’ then… Cheers
for testing DateFormula-variables against 0DF the standard uses a global variable with Name “0DF” of Type DateFormula. This Variable can be used like IF “Starting Date Formula” = “0DF” then or TESTFIELD(“Starting Date Formula”,“0DF”);
It’s a very old question, but none the less I’m still looking for the answer, as the one suggested here doesn’t really work!
The only way I have found so far is to first clear a defined Date Formula var and then compare with this one. But is it really the best way?
CLEAR(NewDFvar);
IF DFfield = NewDFvar THEN DoSomethingWhenDFisNull;
Must just point out that I also know the other way to do this check
IF FORMAT(DFField) = ‘’ THEN DoSomethingWehDFisNull;
But I don’t really like this one either!
Has far I know there isn’t any function to do that.
I could just as well ask if there are any way manually to assign values to DateFormula fields other than use ex. EVALUATE(x,’<1M’)