Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Can anyone identify what is wrong with this in my script please? It is failing at the red part.
TEMPTABLE:
LOAD
UNIT.SOLD_MONTH,
%_BNO
FROM [$(QVD_Path)\BUYER_unit.qvd](qvd);
left join (TEMPTABLE)
load
%_BNO,
max(UNIT.SOLD_MONTH) as MAX.SOLD_MONTH
resident TEMPTABLE;
BUYER_UNIT_TABLE:
load
if(UNIT.SOLD_MONTH >= MonthStart(addmonths(MAX.SOLD_MONTH,-2)) and UNIT.SOLD_MONTH < Monthstart(addmonths(MAX.SOLD_MONTH,1)), 'Active') as BUYER_BUYING_STATUS,
%_BNO
resident TEMPTABLE;
drop field MAX.SOLD_MONTH;
drop table TEMPTABLE;
Thanks
load
%_BNO,
max(UNIT.SOLD_MONTH) as MAX.SOLD_MONTH
resident TEMPTABLE
GROUP BY %_BNO;
load
%_BNO,
max(UNIT.SOLD_MONTH) as MAX.SOLD_MONTH
resident TEMPTABLE
GROUP BY %_BNO;
Hi,
when use any aggregation function (eg-sum(),max(),avg()) in script,then it is mandatory to use group by with respect to
all dimensions.
Thanks,
Raghvendra