Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
Make your voice heard! Participate in the 2020 Wisdom of Crowds® Survey. BEGIN SURVEY
paulista
New Contributor III

Which is the best way to perform an operation on already loaded table

Hi ,

 

I am new to Qlikview and want to perform following operation which i did in Teradata on the already loaded tables in qlikview

 


SELECT Count (DISTINCT hdr_corr_id), HDR_EVT_TYPE FROM
(
SELECT HDR_CORR_ID,HDR_EVT_TYPE,max_date
FROM JOURNEY_VIEW b
INNER JOIN
(SELECT HDR_CORR_ID AS id,Max(HDR_TIMESTAMP) AS max_date
FROM jOURNEY_VIEW
GROUP BY HDR_CORR_ID) a
ON b.hdr_corr_id=a.id
AND max_date=hdr_timestamp
) TAB
GROUP BY HDR_EVT_TYPE

WHat would be best way to do it , in the script or front end.

 

If its a script what would be the best possible script 

Also i can do this in Extract statement when i Load the data --would it be a good practice.

Thanks 

3 Replies
Highlighted

Re: Which is the best way to perform an operation on already loaded table

You can simply use this in Qlik

Table:

Load *;

SQL SELECT Count (DISTINCT hdr_corr_id), HDR_EVT_TYPE FROM
(
SELECT HDR_CORR_ID,HDR_EVT_TYPE,max_date
FROM JOURNEY_VIEW b
INNER JOIN
(SELECT HDR_CORR_ID AS id,Max(HDR_TIMESTAMP) AS max_date
FROM jOURNEY_VIEW
GROUP BY HDR_CORR_ID) a
ON b.hdr_corr_id=a.id
AND max_date=hdr_timestamp
) TAB
GROUP BY HDR_EVT_TYPE;

Store Table into 'Path/Table.qvd';

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Highlighted
paulista
New Contributor III

Re: Which is the best way to perform an operation on already loaded table

Hi Anil,

 

this is what i am doing, but creating a QVD for a simple calculation, would it make sense?is it preferable to store a number of QVD's?

 

how can i do it in just in Resident Load or just in Set Analysis 

Highlighted
Digital Support
Digital Support

Re: Which is the best way to perform an operation on already loaded table

The best thing I can do is provide you the Help link on QVD files, to see the full explanation there and use cases to see if that helps you decide which way to go, but from past experience with customers, generally QVD files are used when they do not wish to hit the backend DB heavily to pull the full set of data etc.  

https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/QVD_files.htm

Here is a link to the Design Blog area of Community as well, there are hundreds of how-to posts from our internal experts that may be of help too in giving you further ideas on things.

https://community.qlik.com/t5/Qlik-Design-Blog/bg-p/qlik-design-blog

Hopefully this in addition to what Anil gave you helps give you a better overall set of knowledge to make a more informed decision on which way to go with this use case. 

Regards,
Brett

To help users find verified answers, please don't forget to use the "Accept as Solution" button on any posts that helped you resolve your problem or question.