Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dears,
i need to enhance the performance for one load that contains a max(xxxxx); let us take an example:
I'm loading from Table:
A:
load
ID,
Item&Date(Date#(Num(DateINV),'YYYYMMDD),'YYYYMMDD') as Key,
Max(Date_Time) as Today_Inventory_Date,
qty as CurrentQTY
from A.qvd
group by ID, Item, DateINV,qty;
Left Join
Load
ID,
Item&Date(Date#(Num(DateINV),'YYYYMMDD)-1,'YYYYMMDD') as Key,
Min(Date_Time) as YesterDay_Inventory_Date,
qty as YesterdayQTY
from A.qvd
group by ID, Item, DateINV,qty;
I need to differentiate between the two inventory time and keep it in the same table and this working fine with me but the Max it is very slow and i need a way to make it faster.
Why do I need to do that? I need to get on the same row the current inventory qty and yesterday qty on the same row.
I change all logic in my script and it works.
Try taking Date_Time in number format. Number format takes less memory than Date formats, this might enhance the load a bit.
I change all logic in my script and it works.