Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

alexandermllr
Not applicable

Timestamp Format problem

Hello,

I have a problem wih the timestamp format, this is my script:

if(Start_time = 'leer',Previous(Start_time )-Time(1/1440,'mm'),(Start_time )) as Start_time,


I always get the previous time - 1 min not in a timestamp format.

Start_time.PNG

How can I get always a timestamp?

Thank you!

1 Solution

Accepted Solutions
prieper
Not applicable

Re: Timestamp Format problem

TIMESTAMP is just a formatting. Calculation itself is done on pure numbers.

Suggest to use

TIMESTAMP(if(Start_time = 'leer',Previous(Start_time )-(1/1440),(Start_time ))) as Start_time

instead.


Peter

2 Replies
prieper
Not applicable

Re: Timestamp Format problem

TIMESTAMP is just a formatting. Calculation itself is done on pure numbers.

Suggest to use

TIMESTAMP(if(Start_time = 'leer',Previous(Start_time )-(1/1440),(Start_time ))) as Start_time

instead.


Peter

alexandermllr
Not applicable

Re: Timestamp Format problem

Thank you very much !!