How to Validate timestamp with milliseconds in Transformer
Posted: Thu Feb 10, 2011 4:54 pm
Hi,
I am getting timestamp string (varchar(17) ) with milliseconds.
Now using transformer i want to validate whether Timestamp is in correct format with correct value.
I am doing this:
If IsValid('TimeStamp', CL.crctn_dltn_ts) Then SetNull() Else "2010".
But its not validating milliseconds i.e it is returning null for all the below mentioned timestamp values.
Its only validating Timestamp upto 14 character and ignoring milliseconds part.
2010-12-21 10:10:10.123
2010-12-21 10:10:10 123
2010-12-21 10:10:10.abc
2010-12-21 10:10:10.123456
Please advise ASAP.
Regards
~Nirmal
I am getting timestamp string (varchar(17) ) with milliseconds.
Now using transformer i want to validate whether Timestamp is in correct format with correct value.
I am doing this:
If IsValid('TimeStamp', CL.crctn_dltn_ts) Then SetNull() Else "2010".
But its not validating milliseconds i.e it is returning null for all the below mentioned timestamp values.
Its only validating Timestamp upto 14 character and ignoring milliseconds part.
2010-12-21 10:10:10.123
2010-12-21 10:10:10 123
2010-12-21 10:10:10.abc
2010-12-21 10:10:10.123456
Please advise ASAP.
Regards
~Nirmal