Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Retrieve list of n largest tables in a db
ozonefilter_at_gmail.com wrote:
> Hello,
>
> is there an easy way to retrieve a list of the largest tables in a
> given Oracle database? I know how to estimate the size of a single
> table, but I was wondering if there was a query that could be used to
> obtain a list of the 20 (for example) top largest
> tables. I know this can be coded on the client side within the
> application by retrieving the size of all the tables in a database and
> then selecting only the largest n tables, but I was looking for
> something
> more efficient and just a query if possible.
>
> Thanks in advance.
First, you'll need to specify the criteria used to define 'table size'. Are you measuring by the number of rows? Extents? Blocks? Bytes?
Look at the definition of the view DBA_TABLES (or USER_TABLES or ALL_TABLES) Received on Wed Dec 13 2006 - 17:18:52 CST