Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
pranaview
Creator III
Creator III

Converting a Macro Datetime format into Qlik readable timestamp

Hi Guys,

I am getting an macro-enabled excel file which has the date and time in the file name which I require to load in to qlik using FileBaseName() function. 

The date time format is as such  "dd-mm-yyyy hh mm AMPM"   for ex:  28-03-2019 04 32 PM

Now when i'm loading it into qlik, i need to convert it into a proper date time format. Kindly let me know what function or combination of functions that i can use to achieve this.

Thanks for the support!

Pranav

Labels (4)
1 Solution

Accepted Solutions
PrashantSangle

Timestamp(Timestamp#(FileBaseName(),'DD-MM-YYYY hh mm TT'),'YourRequiredFormat') as datetime;

Regards,
Prashant Sangle
Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂

View solution in original post

2 Replies
PrashantSangle

Timestamp(Timestamp#(FileBaseName(),'DD-MM-YYYY hh mm TT'),'YourRequiredFormat') as datetime;

Regards,
Prashant Sangle
Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
pranaview
Creator III
Creator III
Author

Thanks Prashant, that worked just fine!