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

Date

Hi Experts,

I am getting data source files date in this format " 12/12/2015  9:00:00 AM " but going forward I will get date format like " 12/12/2015  9:00:00 09" in place of "AM" I will get some number. Anyhow am not using time part in my dashboard. But if they change date format will it impact my current dashboard? Please Suggest me

Thank You

1 Solution

Accepted Solutions
jagan
Luminary Alumni
Luminary Alumni

Hi,

If you are not using Time part then try like below

LOAD

Date(Date#(Left(FieldName, 10), 'MM/DD/YYYY'), 'DD-MMM-YYYY') as Date,

,

,

FROM DataSource;


Regards,

jagan.


View solution in original post

7 Replies
sunny_talwar

May be truncate the time part:

Date(Date#(Left(TimeStampField, 10), 'MM/DD/YYYY')) as Date

Assuming your date format is MM/DD/YYYY

Not applicable
Author

Hi Sunny,

I am loading data in this format

Date(Floor(Date#(Extraction_Date, 'YYYY-MM-DD hh:mm:ss TT'))) AS ExtractionDate. But in Dashboard am using 'DD-MMM-YYYY' format. If they change in data source will it impact to Dashboard? Now in data source they were planning to add some number in place of "AM & PM "

settu_periasamy
Master III
Master III

Hi Jack,

Suppose if you are getting the format "12/12/2015  9:00:00 09", your mentioned statement won't work. May be you can change your statement as suggested by sunny.

or you can try this too.


=Date(Floor(Date#(SubField('2015-12-12 9:00:00 09',' ',1),'YYYY-MM-DD')))


Not applicable
Author

Sorry,

My Date format is now " 12/12/2015  9:00:00 AM " in AM & PM format. Going forward it will change to 24 hour format no more AM & PM in Date.

For example: Time Part

09:30 AM to 09:30

01:25 PM to 13:25

11:59 PM to 23:59

So this changes will impact my current dashboard?

jagan
Luminary Alumni
Luminary Alumni

Hi,

If you are not using Time part then try like below

LOAD

Date(Date#(Left(FieldName, 10), 'MM/DD/YYYY'), 'DD-MMM-YYYY') as Date,

,

,

FROM DataSource;


Regards,

jagan.


jagan
Luminary Alumni
Luminary Alumni

Yes this will impact.  If you are not using Time part then use like below

LOAD

Date(Date#(Left(FieldName, 10), 'MM/DD/YYYY'), 'DD-MMM-YYYY') as Date,


Regards,

Jagan.

Not applicable
Author

Thank You All