Hi,
The task you presented to us is a bit tricky because you wont both text "Not Credible" and Dates in the same column. Thus, assuming that your Column 2 dates are entered as numbers (no leading "0" for month < 10) and that the order of the day - month - year is always the same, here is a formula that should do the trick:
DATEIN = Char( :Column 2 );
DATEOUT = "";
If( !Is Missing( :Column 1 ),
If( !Is Missing( :Column 2 ) & Is Number( :Column 2 ),
If(
Length( DATEIN ) == 8,
DATEOUT = Format( Informat( DATEIN, "mmddyyyy" ), "ddMonyyyy" ),
Length( Char( DATEIN ) ) == 7,
DATEIN = "0" || DATEIN;
DATEOUT = Format( Informat( DATEIN, "mmddyyy" ), "ddMonyyyy" );
)
,
DATEOUT = "Not Credible"
)
,
DATEOUT = "."
);
DATEOUT;
I intentionally used local variable to make the formula more readable but it is not really required.
Let us know if that works for you.
Best,
TS
Thierry R. Sornasse