Qlik Community

Ask a Question

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
QlikWorld starts MONDAY! last chance to register is now ! REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
jasmeenkr
Contributor
Contributor

Extract time from dateTime field

Hi all,

 

I have requirement to get Time only from DateTime field which has values in format M/DD/YYYY hh:mm:ss TT

 

How to achieve it?

Labels (4)
4 Replies
sunny_talwar

May be this

Time(Frac(DateTimeFieldName)) as Time
jasmeenkr
Contributor
Contributor
Author

It gives me integer number . I have used subfield function to get time part. 

My next step is to join it to DimTime which has hour column of type varchar 12:00 AM/PM.

How to make join work

jasmeenkr
Contributor
Contributor
Author

I added Time(Frac(DateTime),'h:mmTT') as TimeSk in Fact. Now when i join it with DimTime TimeSk,

I am getting wrong bargraph as attached

 

Any help appreciated

sunny_talwar

Difficult to know without a sample file to look at