I have a query that works fine when ordered by the puller id (cf.op.id). The problem comes when I try to order by the sum of the boxes (sum(cf.qq)).
I have read "UniVerse SQL Reference" and "UniVerse SQL User Guide". I don't see any way possible to display the results the way I want.
This is my working query.
My Results.
My Desired Results
Does anybody know how to group by sum(cf.qq) and get the desired results?
I have read "UniVerse SQL Reference" and "UniVerse SQL User Guide". I don't see any way possible to display the results the way I want.
This is my working query.
Code:
SELECT SQL+CF.OP.ID, SUM(CF.QQ) SQL+FROM UNNEST PICK.TRANS.HDC ON CF.OP.ID SQL+WHERE CF.QQ > 0 SQL+GROUP BY CF.OP.ID;
Code:
Cf.op.id SUM ( CF.QQ ) AAM 4 ABC 1 ADB 56 ADD 2 ADH 2
Code:
Cf.op.id SUM ( CF.QQ ) ADB 56 AAM 4 ADD 2 ADH 2 ABC 1
Comment