DBA_Extents script

Posted on 2007-07-25
Last Modified: 2008-02-01

Can ypu tell me what this script does? i need to run it after the database backup...
I am runnning  oracle 8 on window
Question by:jung1975
    LVL 142

    Accepted Solution

    you run it just like that? that will just dump all the extends of that owner, excluding the very first extend_id
    LVL 34

    Assisted Solution

    by:Mark Geerlings
    The script will simply give you a list of the records from the data dictionary view: dba_extents for the owner (schema) "test" if that object is not the first on in a tablespace.  Every Oracle database contains this view which lists: the Oracle owner/schema name; the object name; the tablespace_name; and some size information for every table and index in the database.

    I cannot imagine what value this script would add.  But it can't do any harm, other than take a second or two of CPU time to answer a question that seems to have little value.
    LVL 34

    Expert Comment

    by:Mark Geerlings
    And, the version of Oracle (Oracle8 in your case) and the version of the server O/S (Windows) makes no difference.  This query works the same in any Oracle database on any O/S.

    Author Comment

    if the result found for query then, table must be rebuilt with larger size?
    am i suppose to getting no data?
    LVL 34

    Expert Comment

    by:Mark Geerlings
    I just realized that there is an error in the query you posted.  It cannot run with "extent_id", that must be: "extents", then it can work.

    No, you don't need to rebuild a table just because this query returns it.

    If you get no data, that just means that one of these conditions is true:
    1. There is no schema named: "test" (and if you run the query with lower case values ('test', not 'TEST') I would expect no rows to be returned because Oracle owner (schema) names are usually (if not always) uppercase values
    2. The objects owned by 'TEST" all have only one extent (which is good).

    Featured Post

    Courses: Start Training Online With Pros, Today

    Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

    Join & Write a Comment

    Article by: Swadhin
    From the Oracle SQL Reference ( we are told that a join is a query that combines rows from two or more tables, views, or materialized views. This article provides a glimps…
    I remember the day when someone asked me to create a user for an application developement. The user should be able to create views and materialized views and, so, I used the following syntax: (CODE) This way, I guessed, I would ensure that use…
    Via a live example, show how to take different types of Oracle backups using RMAN.
    This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

    746 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now