Sure.

It's called a Union to bring in the separate query with 'Total' as Name, and
dummy values for ID and elsewhere as needed.  I have even added an extra col
for the grouping and or sorting as needed.

I have been faking output like this for years with that trick.

Say how is the brewing?


__Stephen

On 11/6/07, Matthew Jarvis <[EMAIL PROTECTED]> wrote:
>
> Has anyone ever come up with a way to have a SQL statement add a line at
> the end that consists of totals of all the previous lines? Is something
> like that even possible?
>
> For example, if this would be the result of my SQL code:
>
> ID      Name    Amount  Tax
>
> 4       Matt    3       .10
> 2       Joe     2       .10
> 5       Tim     6       .10
>
>
> It would be convenient to have it come out like this:
>
> ID      Name    Amount  Tax
>
> 4       Matt    3       .10
> 2       Joe     2       .10
> 5       Tim     6       .10
> Total           11      .30
>
>
> Or something like that....
>
> --
> Matthew S. Jarvis
> IT Manager
> Bike Friday - "Performance that Packs."
> www.bikefriday.com
> 541/687-0487 x140
> [EMAIL PROTECTED]
>
>
[excessive quoting removed by server]

_______________________________________________
Post Messages to: ProFox@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: http://leafe.com/archives/byMID/profox/[EMAIL PROTECTED]
** 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.

Reply via email to