You are not logged in.
Announcement
Unanswered posts
|
Pages: 1

Hi,
Please check the screenshot where the redlined areas are highlighting the Preceeding zeros of Month, have removed while date conversion.
This is how i'm manipulating it:
String.valueOf(TalendDate.getPartOfDate("YEAR",TalendDate.parseDate("yyyy-MM-dd hh:mm:ss", String.valueOf(row1.timestamp) )) )
+"-"+
String.valueOf(TalendDate.getPartOfDate("MONTH",TalendDate.parseDate("yyyy-MM-dd hh:mm:ss", String.valueOf(row1.timestamp) )) )
Is that a correct way?
Offline

This will only return an integer. If you want the '03' you are going to have to convert to a string and index the part of the date you want using string handling methods.
Offline
Pages: 1