Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Discover how organizations are unlocking new revenue streams: Watch here
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

string to date

Hi,
I have a string like that "16/01/2008 09:04:12 AM" and i need to have a date from this string.
i try with TalendDate.parseDate("dd/MM/yyyy HH:mm:ss aa", madate) but it doesn't work.
the log is Unparseable date: "16/01/2008 09:04:12 AM"
Have u got an idea to help me ?

Labels (2)
20 Replies
vapukov
Master II
Master II

My data is coming like this 2016-10-15 16:50:11, I want this in yyyymmdd format.How can I do this by using Tmap.
Can any one please suggest.
Appreciate for help.
Thanks its done now .

it depend from how Your data coming - as string or as date? ad what output format - string or date
in any case it is combination of TalendDate.formatDate and TalendDate.parseDate
for example if it coming as date and output as string
TalendDate.formatDate("yyyyMMddHH",dateColunName)
if it coming as string and must be converted to string as well:
TalendDate.formatDate("yyyyMMddHH",TalendDate.parseDate("yyyy-MM-dd HH:mm:ss","2016-10-15 16:50:11"))
In tMap when You open Build Expression windows You can read short information about each function (not all but many of them) - look for input and output values, like on pictures
0683p000009MADM.jpg    0683p000009MADD.png