Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

sql plus reporting "compute sum on " in SQL PLUS

Status
Not open for further replies.

umeman

Technical User
Oct 2, 2001
59
US
Hi,

I am trying to compute a sum of a certain column in sql plus
however the sum line is not appearing

I have done the following:

clear computes
compute sum of amount on report

but when I do the same on the scott/tiger schema
the compute works fine.

Is there something that I am perhaps forgetting ?

Please help

-U-
 
Are all AMOUNT values non-null? COMPUTE SUM only works on non-null values.

What does your SELECT statement that follows the COMPUTE look like?

The rules for COMPUTE,according to ORACLE:
** One or more of the expressions, columns, or column aliases you reference in the OF clause must also be in the SELECT command.
** The expression, column, or column alias you reference in the ON clause must occur in the SELECT command and in the most recent BREAK command.
** If you reference either ROW or REPORT in the ON clause, also reference ROW or REPORT in the most recent BREAK command.


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top