Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I Have the follow script in a QV Model, but it takes too long to run, especially at the "group by".
Could you help me to optimize it?
Thanks,
Felipe
LOAD
PH_SERIAL_NO,
MaxString(Color) as Color,
max(PH_Life_Liters) as PH_Life_Liters,
max(PH_Life_Time) as PH_Life_Time,
max(Last_Machine_Last_Report_Day) as Last_Machine_Last_Report_Day,
MaxString(Last_PROD_NR) as Last_PROD_NR,
MaxString(Last_SRL_NR) as Last_SRL_NR,
ApplyMap('mapLV',maxstring(Last_PROD_NR), 'Other') as Last_PROD_NAME,
max(IsDead) as IsDead,
Maxstring(Warranty_PH) as Warranty_PH,
PH_Last_Report_Day,
PH_Last_Report_Month,
PH_Born_Day,
PH_Born_Month,
Max(Last_PEN) as Last_PEN
Resident TaulaIntermitjaEriquiana
Group By PH_SERIAL_NO,PH_Last_Report_Day,PH_Born_Day,PH_Born_Month,PH_Last_Report_Month;
DROP Table TaulaIntermitjaEriquiana;
Check this link out... Optimize Group By Performance. This has helped in few cases and not in other. But I would say it is worth giving it a shot to see if this improves the reload time for you.
An incremental load-aproach is often useful to minimize the load-times. On the bottom of the follwing post you will find various examples for incremental loadings and also exists() to keep the qvd-loadings optimized: Advanced-topics-for-creating-a-qlik-datamodel.
- Marcus