Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello There,
I ham trying to put below expression in Load script
aggr(sum(Filedname1),Filedname2) as Test1
aggr(sum(Filedname1),Filedname2, Filedname='ABC') as Test2
it is giving error. How can i put this expression into script while loading?
Thanks,
Siva
-------------1--------------
load
FieldName2
sum(Fieldname1) as Test1
from... group by FieldName2
-----------------2------------
load
FieldName2
sum(Fieldname1) as Test1
from... where FieldName='ABC' group by FieldName2
Hi,
Can you explain a bit more what you're trying to achieve? Looking at the description of the aggr() function are you sure it is meant for use in the load statement? It looks like it is more appropriate as a chart function. An example qvw will be really helpful. Also, have you included "group by" in the load statement? If you're using SUM() it will normally be required.
Cheers,
Emma
aggr() function is not applicable at script level use
Load Filedname2,sum(Filedname1) as Test1 Resident Table1 Group by Filedname2;
Kiran.
-------------1--------------
load
FieldName2
sum(Fieldname1) as Test1
from... group by FieldName2
-----------------2------------
load
FieldName2
sum(Fieldname1) as Test1
from... where FieldName='ABC' group by FieldName2