Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Load DateTimeStamp as Date only

How to load only the date portion of a Timestamp.  I tried using 'DayStart(DTSTAMP) as T_Day, but it comes across with 12:00:00 AM.  I want it to show as MM/DD/YYYY only.  When I tried the date# interpretation, it came across as text (I assume since the values were left-justified when shown in a list box).


1 Solution

Accepted Solutions
Not applicable
Author

try Date(Floor(DTSSTAMP), 'MM/DD/YYYY')  AS [MyDateTimeStamp]

View solution in original post

4 Replies
Not applicable
Author

try Date(Floor(DTSSTAMP), 'MM/DD/YYYY')  AS [MyDateTimeStamp]

MayilVahanan

Hi

Try like this

Date(Date(DTSTAMP, 'MM/DD/YYY hh:mm:ss TT'),'MM/DD/YYYY')

or

Date(Date#(DTSTAMP, 'MM/DD/YYY hh:mm:ss TT'),'MM/DD/YYYY')

note :'MM/DD/YYY hh:mm:ss TT' must matches your timestamp format

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
Anonymous
Not applicable
Author

All correct, just adding one more:

date(DayStart(DTSTAMP), 'MM/DD/YYYY') as T_Day

gareth_muir
Contributor II
Contributor II

I tried to use these but my qlik app kept coming up with a blank where I wanted an MM-YY list.

Eventually I had to separate out the MM/DD/YYYY text string inside of the Timestamp generated by my ERP, and use the DATE syntax. I did it with a left search formula which worked great -

Date(Monthstart(Left([inDateAdded],10)),'MM-YY') as Month_Scraped, //Default date format is MM/DD/YYYY hh:mm:ss.ffff