Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: How to count total number of rows from all user-tables
If your environment does an "ANALYZE TABLE" for all tables each day, then
you can
get a relatively good count from USER_TABLES.NUM_ROWS.
"shinwar" <jshinwar_at_yahoo.com> wrote in message
news:77e5857.0210031319.47f28818_at_posting.google.com...
> Hi, Oracle Gurus
>
>
> Before this I have posted one question. Now, I have one more question
> on how to count total number rows of each user table using a single
> query statement. I really do not know if it can be done in a single
> SQL statement. Let's say. I have 100 user tables. I do not want to
> issue 100 SQL commands for this job.
>
> Instead, using a single SQL which uses user_ind_columns.table_name, I
> like to find total number of rows of all my tables. The output should,
> for example, be in this format:
>
> user-tables total_no_of_rows
> ----------- -----------------
> table1 99999
> table2 99999
> ....
> ....
>
> Appreciate any of your advise. Thank you for your valuable time.
Received on Fri Oct 04 2002 - 13:38:15 CDT
![]() |
![]() |