SQL query with GROUP BY doesn't work, Why?
Posted: Mon Aug 25, 2014 9:32 pm
I have this code on MYSQL
Running the query direct on the database, brings the actual result like this..
Line1 986897
Line2 17329271
Line3 3934390
Line4 202100
Line5 3689419
Running the code on a report on nuBuilder do not get SUM,
I wonder what am i missing to amke this totals work on nubuilder?
Line1 22530
Line2 105279
Line3 64080
Line5 101050
Line6 97688
I am running the report with a button with and "onclick" Event nuPrintPDF('01_quotes_by_line');
Please help.
I also notice that if I place the code on the SQL on a form, it doesn't bring the total per `line`
Is it that GROUP BY is invalidated by nubyuilder, If so, what is the turn around.
I would appreciate answer with example.
Thank you

Code: Select all
SELECT `line`, sum(`value`) FROM `la_quotes` GROUP BY `line`
Line1 986897
Line2 17329271
Line3 3934390
Line4 202100
Line5 3689419
Running the code on a report on nuBuilder do not get SUM,
I wonder what am i missing to amke this totals work on nubuilder?
Line1 22530
Line2 105279
Line3 64080
Line5 101050
Line6 97688
I am running the report with a button with and "onclick" Event nuPrintPDF('01_quotes_by_line');
Please help.
I also notice that if I place the code on the SQL on a form, it doesn't bring the total per `line`
Is it that GROUP BY is invalidated by nubyuilder, If so, what is the turn around.
I would appreciate answer with example.
Code: Select all
SELECT `line`, sum(`value`) FROM `la_quotes` GROUP BY `line`
