|
I'm trying to add final totals to an SQL listing.
Struggling with the syntax a bit.
Below SQL lists all spoolfiles on the system, sorted descending by size
SELECT OUTQ, SPOOLNAME, size, pages, job_name, created
FROM QSYS2.OUTPUT_QUEUE_ENTRIES
ORDER BY SIZE desc
I have a 2nd SQL showing only the sum.
SELECT sum(pages)
FROM QSYS2.OUTPUT_QUEUE_ENTRIES
SELECT statement run complete.
SUM ( SIZE ) SUM ( PAGES )
489,542,320 81,492,452
What I would like to see is the listing with the sum at the bottom.
Do I need a union to do this?
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.