Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
harson
New Contributor III

Load data into a temporary table

Hello Community,

I need help.

My situation :

I have several rows of data for the years 2015,2016 and 2017 in my database while my QlikView report must output a graph every day with the existing data (from 2015 to 2017)
My problem is that loading data from 2015 to 2017 takes a long time.
What I would like to do then, if possible on QlikView, is to load the data from January 2015 to the previous month of the current month for 2017 early in the month.

For example :
On 1 May 2017, I load a temporary table containing the data from 01 January 2015 to 30 April 2017.
Then during the month of May, for my report, I will only reload the data of the month of May, the remains I take them just in my temporary table to avoid reloading the data from 01 Jan 2015 to May 2017 (max date), Since the data from 01 January 2015 to 30 April 2017 no longer change, they are no longer modifiable when we move to a new month.

Thanks in advance for your help.

Tsiry

1 Reply
ankitaag
Contributor III

Re: Load data into a temporary table

Hi Tsiry,

You can first save your historical data in one QVD (HistoryData) and make a separate QVD when fetching current month's data (Current Data).

This way your history remains constant always and just the current month's data will change. Then later concatenate the two QVDs and override the HistoryData qvd.

For ex-


vCurrentMonth=May 2017;


CurrData:

Load *

From table

where MonthYear='$(vCurrentMonth)';

HistoryData:

Load *

From HistoryData

where MonthYear<>'$(vCurrentMonth)';


Store CurrData into [path\HistoryData.qvd] (qvd);


The above condition in 2nd load "'where MonthYear<>'$(vCurrentMonth)';" is required so that when you concatenate and store the data, current month's data doesn't get duplicate.


Hope this helps!


Thanks and Regards,

Ankita

Community Browser