Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
To execute the query and write it line by line in CSV file:
SET MinDate = '01.01.2008';
SET MaxDate = '31.12.2009';
let IntervDate =Date(MinDate+1);
DO WHILE MinDate<>MaxDate
StTable:
LOAD [Location Code],SUM([Quantity]) Resident RawData
WHERE [Entry Type]='Buy' AND DateForRaw<=$(MinDate)
GROUP BY [Location Code];
STORE StTable into Table.csv;
DROP TABLE StTable;
let MinDate =Date(MinDate+1);
LOOP
I need help.
Try enclosing the date variable expansion into single quotes:
LOAD [Location Code],SUM([Quantity]) Resident RawData
WHERE [Entry Type]='Buy' AND DateForRaw<='$(MinDate)'
GROUP BY [Location Code];