Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
ManojKD
Contributor
Contributor

Invalid dates ex: "2020-02-31" are converted without error

Hi All,

 

I tried to convert few  dates (which is in string format) to date of format "yyyy-mm-dd" using Talenddate.Parse date and write in a file. The source data have some invalid dates like "20200231", "20191131" etc. The expectation is to get an error that the date "2020-02-31" is invalid, as February and November will never get day 31. But those values are converted to date  and written in file as "20200231", "20191131". Which is not a right data. How to capture this?

 

 

Labels (2)
1 Solution

Accepted Solutions
manodwhb
Champion II
Champion II

@ManojKD ,checck the below screenshot,you need check the below way.

 

TalendDate.isDate(row6.sting_date,"yyyyMMdd")

 

 

0683p000009M8bC.png

View solution in original post

1 Reply
manodwhb
Champion II
Champion II

@ManojKD ,checck the below screenshot,you need check the below way.

 

TalendDate.isDate(row6.sting_date,"yyyyMMdd")

 

 

0683p000009M8bC.png