qlikview query taking long time to execute

374 views Asked by At

I am Loading data in qlikview through a flat file, the data is loaded in the table called imported. from the table imported a table called Transaction_details loads data.

the query I am using is

Transaction_details:
Load
  KEY,
  Line_number,
  KEY&Line_number AS Line_key, 
  currency, 
  ExchRate,
  Account,
  [Account Text],
  [Cost Ctr], 
  [WBS Element],
  [Line Text], 
  [TC Amount], 
  [LC Amount], 
  [D/C], 
  [Tax Code],
  [Account Type],
  CoCode
  Resident imported ;

after that I want to do some calculations in another table and Join it back to the main table transaction_details

the table I have created for calculations is called sums:

SUMS:
load
    distinct KEY
resident  Transaction_details;

 LEFT JOIN (SUMS)
 Load
 KEY,
 SUM([LC Amount]) as [LC AMOUNT SUM]
 RESIDENT Transaction_details
 GROUP BY KEY;

the original table transactions_details have around 400 million rows, for some reason this simple group and sum in sums table is taking long time, I am running from past 4 hours now. is there a better way of doing this , and can some one guide me to the qlikview query performance.

1

There are 1 answers

0
ralfbecher On

You don't need the first SUMS Load statement, just try:

SUMS:
 Load
 KEY,
 SUM([LC Amount]) as [LC AMOUNT SUM]
 RESIDENT Transaction_details
 GROUP BY KEY;

You could then join other calculations to this table.

However, I wonder why you want this because QlikView will aggregation on the fly in charts.