Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have the following script
OCfinal:
LOAD [OC] ,DEBUT
,FIN ;
SQL SELECT distinct [OC]
,[DATE DEBUT] AS [DEBUT]
,[DATE FIN] AS [FIN]
FROM [dbo].OCfinal
WHERE [Code Article] IS NOT NULL ;
Vente:
LOAD
.....
from vente
LEFT JOIN(Vente)
IntervalMatch (datecol)
LOAD DISTINCT [DATE DEBUT]
,[DATE FIN]
resident OCfinal
;
LEFT JOIN (Vente)
LOAD *
RESIDENT OCfinal;
How to optimize it ?
Don't join the Interval Match table and the OCfinal table together and leave the synthetic key in there. Look at hic comments on the following blog: IntervalMatch
Screenshot from the above blog:
Don't join the Interval Match table and the OCfinal table together and leave the synthetic key in there. Look at hic comments on the following blog: IntervalMatch
Screenshot from the above blog: