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

Problem with dates

Hi,

I'm using the followin script:

Data:
select
(select top 1 name from labelfile where labeldefinition='ReasonLate' and abbr=stp_reasonlate) as reasonlate,
stp_schdtlatest,
stp_arrivaldate,
lgh_Carrier,
orderheader.ord_hdrnumber as TMWO

from stops
left join orderheader on orderheader.ord_hdrnumber=stops.ord_hdrnumber
left join legheader on stops.lgh_number=legheader.lgh_number
where (stp_arrivaldate>getdate()-31) and
  ((stp_reasonlate<>'UNK')or(stp_arrivaldate>stp_schdtlatest));
  
Data2:
Load
date(stp_schdtlatest) as Date, *

Resident Data;

DROP table Data;

Now in my table, I want the dimension "Date" on the vertical axis. However, I get something like this:

naamloos.JPG

How do I combine all date for one date in my table? (so all the data combined, and in the dimension only once 18-03, 19-03, etc.)

Thanks!

Niek

1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Use

date(floor(stp_schdtlatest)) as Date

Your stp_schdtlatest field is obviously timestamp, not a date.  Function floor() removes the fraction part (time)


View solution in original post

5 Replies
Anonymous
Not applicable
Author

Use

date(floor(stp_schdtlatest)) as Date

Your stp_schdtlatest field is obviously timestamp, not a date.  Function floor() removes the fraction part (time)


rustyfishbones
Master II
Master II

It probably means your Date is not formatted correctly

alexandros17
Partner - Champion III
Partner - Champion III

It seems you have date - time field, if it is so, when you load try to cast the date as DD/MM/YYYY

Not applicable
Author

Thanks!

rustyfishbones
Master II
Master II

YOU CAN TRY

2014-04-18_1340.png