Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

hectorvega
New Contributor III

Session date format distinct on new version 12

In the recent version the date and time stamp in the records of sessions*.log changed.

For example, now the [Session Start] field is shown as  "20160428T105540.000-0600"

Please note the T embeded on the field value.

I need to read all the files for the sessions with :

LOAD

    Document,

   [Session Start],

   [Session Duration],

   [Bytes Received],

   [Authenticated user],

   1 as CountLogin,

    Year([Session Start]) as YearLogin,

    Month([Session Start]) as MonthLogin,

    Day([Session Start]) as DayLogin,

    Date([Session Start],'yyyy-mm-dd') as DateLogin,

    Time([Session Start]) as HourLogin

FROM 

$(Path)\SESSIONS*.LOG (utf8, txt, delimiter is '\t', embedded labels)

Giving error on the calculations for date's.

Any possible fix in order to get the correct results?

Thank you

HV

Tags (1)
3 Replies
iliyansomlev
Contributor

Re: Session date format distinct on new version 12

Hi,

I want to ask if anyone had provided a fix for this issue?

Also the format for Session duration is in decimal format now. Does anyone know if this is fraction of a Day or an Hour?

Session Duration

0.001019

0.029102

etc

Re: Session date format distinct on new version 12

First you need to change that format to regular format in Qlik. After that your condition should return as expected

iliyansomlev
Contributor

Re: Session date format distinct on new version 12

Yes, I did this and it works. (like Timestamp(Timestamp) as Timestamp).

Also session duration was fixed with interval ([Session Duration], 'hh:mm:ss')

But also have noticed that file paths are now separated with '/' and in QV 11.2 they were with '\'.  Is there any exhaustive list about what is different in the log files in QV 12.20 compared to QV 11.2 ?