cancel
Showing results for 
Search instead for 
Did you mean: 

Date format issue.

sshaikh
New Contributor

Hi All,

I have data type at input as a date fuction and expected same at output. But in mapping I need to keep as blank for the dates are invalid like 0001-01-01 or dates older than 2008-01-01. When I am trying to make an expression in mapper its not working, when I am making it in string type then its working.

Anyone can guide on  how to make an expression so output should be in Date function only.

I have used below expression 

$Date < 2008-01-01 ? " " : $Date  -----> Not worked

$Date.toString() < 2008-01-01 ? " " : $Date.toString() -----> Worked but data type converted into String which is not desired.

Date.parse($Date, yyyy-MM-dd) ----> Not Worked.

I have tried with Type convertor and Date-Time Extractor type snaps but these snaps output is Date-time type.

0 REPLIES 0