Re: Count(*) each table from user_tables

  • From: Edgar Chupit <edgar.chupit@xxxxx>
  • To: "Mihalis I. Tsoukalos" <oracle-l@xxxxxxxxxxxxx>
  • Date: Fri, 2 Jul 2004 09:44:54 +0300

Hello Mihalis,

MIT> I want to count(*) every table from users_table table using SQL.
MIT> I know how to do it in PL/SQL but not in SQL.
MIT> Can you please help me do it?

SQL should know all referenced tables and fields upon parsing, since
you have dynamic list of tables, that will be known only upon
execution, you can not count all fields for all tables in user schema
in single sql.

IF you have precise computed statistics for all tables, maybe you can
use NUM_ROWS field of user_tables instead of count(*).

-- 
Best regards,
 Edgar

----------------------------------------------------------------
Please see the official ORACLE-L FAQ: http://www.orafaq.com
----------------------------------------------------------------
To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx
put 'unsubscribe' in the subject line.
--
Archives are at //www.freelists.org/archives/oracle-l/
FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
-----------------------------------------------------------------

Other related posts: