RE: Problem with GROUP BY

Author: Tracy Pearson

Posted: 2016-02-20 at 14:24:06

When you have an aggregate (the sum), you should group by all the noon-aggregate fields.

You could use the numbers for each field.

Group by 3,1,2,4,5,6

On February 20, 2016 2:53:12 PM EST, jerry foote <jerryf@footegroup.com> wrote:

>

>I have adjusted the code as below and still get error message GROUP BY

>clause is missing or invalid.

>I am running vp8

>

>SELECT manifest_n, bill_of_la, release_no, frm_acct, source, source_id,

>sum(units) as totat FROM SERVICE WHERE manifest_n=2512 AND

>bill_of_la="158401" GROUP BY release_no INTO CURSOR mytotla

>

>

--

Sent from my Android device with K-9 Mail. Please excuse my brevity.

_______________________________________________

Post Messages to: ProFox@leafe.com

Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox

OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech

Searchable Archive: http://leafe.com/archives/search/profox

This message: http://leafe.com/archives/byMID/profox/99C5DA0E-30B1-4E58-89CD-6D8E68BD1A17@powerchurch.com

** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

©2016 Tracy Pearson