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

Home -> Community -> Usenet -> c.d.o.tools -> Re: How do I find emty tables

Re: How do I find emty tables

From: Sybrand Bakker <postbus_at_sybrandb.demon.nl>
Date: Tue, 15 May 2001 20:19:08 +0200
Message-ID: <tg2sksbb43016c@beta-news.demon.nl>

"Niklas Danielsson" <niklas.danielsson_at_eget.fi> wrote in message news:3B0106D8.C42783C_at_eget.fi...
> Hello all!
>
> I would like to find alla tables that are emty = 0 rows in the database.
> The problem is that I can't analyze the the tables so I can't use
> NUM_ROWS in DBA_TABLES.
>
> Is there any other way?
>
> TIA
>
> niklas.danielsson_at_eget.fi
>

If you don't want to do it the easy way, you obviously need to resort to ... select count(*) from <table>
and then a series of them.

You could of course filter out all tables with more than 1 extent (they likely don't need to be counted), but the rest ... no other solution. Yes, it will be slow, as the non-empty tables will be counted.

Regards,

Sybrand Bakker, Oracle DBA Received on Tue May 15 2001 - 13:19:08 CDT

Original text of this message

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