Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: ORA-24347 (null column in aggregate function) - SQL*Plus

Re: ORA-24347 (null column in aggregate function) - SQL*Plus

From: Tim Sawmiller <sawmillert_at_state.mi.us>
Date: Mon, 30 Apr 2001 12:02:29 -0700
Message-ID: <F001.002F5C10.20010430121108@fatcity.com>

Looks like you have user with no objects. Try count(*) instead of count(object_name);

>>> Jacques.Kilchoer_at_quest.com 04/30/01 02:25PM >>>
I'm a little stumped. I'm using SQL*Plus 8.1.6.0.0 client to connect to an Oracle 8.0.5 database on a Windows NT server. I want to get the count of objects for each user, with a 0 count for users without any objects. But when i run the query, errors message ORA-24347 is returned. Why would that be?
When I run the query directly on the server, using a SQL*Plus 8.0.5 client, the query returns the expected data with no errors. Is there a bug in Metalink for this? I didn't find anything, but maybe my searching skills need some honing. Should I stick with older versions of the SQL*Plus client?

Results with 8.1.6 client to 8.0.5 database: SQL> select count (*) from dba_users where username is null ;

  COUNT(*)


         0

SQL> select count (*) from dba_objects where owner is null ;

  COUNT(*)


         0

SQL> select count (*) from dba_objects where object_name is null ;

  COUNT(*)


         0

SQL> select a.username, count (object_name)   2 from dba_users a, dba_objects b
  3 where a.username = b.owner (+)
  4 group by a.username ;
ERROR:
ORA-24347: Warning of a NULL column in an aggregate function



Jacques R. Kilchoer
(949) 754-8816
Quest Software, Inc.
8001 Irvine Center Drive
Irvine, California 92618
U.S.A.
http://www.quest.com
--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: Tim Sawmiller
  INET: sawmillert_at_state.mi.us

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Mon Apr 30 2001 - 14:02:29 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US