Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello - I am fairly advanced in QlikView but I have just started using QlikSense, so I am struggling with some of the limitations.
First, I have a date field formatted as:
02/29/2016 10:00AM |
I would like to remove the timestamp and just format as MM/DD/YYYY, but nothing I have tried seems to be working.
Also, I have a "Length of Stay" field, which determines the length of a clients trip. I would like to add "Length of Stay" to the date field mentioned above to get an Estimated Date of Departure.
i.e
Date field = 05/05/2016
Length of Stay = 5
Calculated Field, Estimated Date of Departure = 05/10/2016
Thanks in advance,
- dave
How about this:
LOAD Date(DATE + [Length of Stay], 'MM/DD/YYYY') as DEPARTURE_DATE
LOAD
"Start Date",
Date(Date#(Left(Trim([Start Date]), 10), 'MM/DD/YYYY'), 'MM/DD/YYYY') as DATE
How about these
Date(Floor(TimeStamp('02/29/2016 10:00AM', 'MM/DD/YYYY hh:mmTT'))) as Date
Sunny - Its not working ... I feel like I am not sure if I am using the right quotations or brackets in the calculation:
LOAD
"Start Date",
Date(Floor(TimeStamp('Start Date', 'MM/DD/YYYY hh:mmTT')))
You are using TimeStamp or TimeStamp#? If timestamp# is still not working, can you try this:
LOAD
"Start Date",
Date(Date#(Left(Trim([Start Date]), 10), 'MM/DD/YYYY')', MM/DD/YYYY') as DATE
Neither of these worked either ... Im not getting a wrong answer, I am just getting nothing in those fields
Check my response above
Error in expression: ')' expected
May bad, try this:
LOAD
"Start Date",
Date(Date#(Left(Trim([Start Date]), 10), 'MM/DD/YYYY'), 'MM/DD/YYYY') as DATE
Nice Sunny. That fixed the timestamp issue ... Now how do I incorporate that into the Est Dept Date calc?
How about this:
LOAD Date(DATE + [Length of Stay], 'MM/DD/YYYY') as DEPARTURE_DATE
LOAD
"Start Date",
Date(Date#(Left(Trim([Start Date]), 10), 'MM/DD/YYYY'), 'MM/DD/YYYY') as DATE