Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
arnould_it
Contributor III
Contributor III

Timestamp order during load from qvd

Hello to all,

Could anyone suggest me how to correctly order records using Timestamp, loading from a qvd?  I've tried in many ways but without success until now.

I've to compare any record with its previous, but to do this the records have to be in ascending order during comparison.

I've also tried ordering records after having loaded them from qvd, using a resident table, but it doesn't work anyway.

This is my timestamp format: 'DD.MM.YYYY hh:mm:ss[.fff]'.

I'm using Qlik Sense.

Thank you in advance for your suggestions

Alessandro

1 Solution

Accepted Solutions
m_s
Partner - Creator II
Partner - Creator II

Are you loading your QVD like

LOAD

    *

FROM qvd-file.qvd(qvd)

ORDER BY Timestamp;

and if yes does it still not work?

If so maybe try adding a field containing the numeric timestamp (Num(Timestamp)) and order by that.

Mathias

View solution in original post

5 Replies
shraddha_g
Partner - Master III
Partner - Master III

What is the format of data in qvd?

Can you share sample data?

arnould_it
Contributor III
Contributor III
Author

This is the original format from a csv file: "04.11.2017 07:00:01"

This is the script set: SET TimestampFormat='DD.MM.YYYY hh:mm:ss[.fff]';

arnould_it
Contributor III
Contributor III
Author

This is a screenshot from the qvd:

qvd_issue.png

it seems ok but when I load it the order sometime changes

m_s
Partner - Creator II
Partner - Creator II

Are you loading your QVD like

LOAD

    *

FROM qvd-file.qvd(qvd)

ORDER BY Timestamp;

and if yes does it still not work?

If so maybe try adding a field containing the numeric timestamp (Num(Timestamp)) and order by that.

Mathias

arnould_it
Contributor III
Contributor III
Author

Thanks Mathias,

using (num(timestamp)) it does work.