DBAsupport.com Forums - Powered by vBulletin
Results 1 to 4 of 4

Thread: Two question.Help

  1. #1
    Join Date
    Oct 2000
    Posts
    23
    hello ,every one here.

    1.
    I was told that an entry of rollback segment is relatived to a SCN which is owned by a transaction.
    I was also told that SCN is given soon AFTER a commit executed.

    My Problem is : Before a transaction commited, does a SCN relative to this
    transaction exist? If not ,what is the entry in rollback segment relatived to it.

    2.
    The question is as following
    All the space in datafile except for the header block can be accounted for in which two data dictionary
    views?

    the correct answer is DBA_EXTENTS and DBA_FREE_SPACE

    But I do not know how can I use this two views to get the information which I want.

    Thank you in advance

  2. #2
    Join Date
    Aug 2000
    Location
    Belgium
    Posts
    342
    (2.)

    select tablespace_name,sum(user_blocks)
    from dba_data_files
    group by tablespace_name
    --> gives you a list how many blocks you can use per tablespace (total )

    select tablespace_name,sum(blocks)
    from dba_segments
    group by tablespace_name
    --> gives you a list per tablespace how many blocks are already in use ( used )

    select tablespace_name,sum(blocks)
    from dba_free_space
    group by tablespace_name
    -> gives you a list per tablespace how many blocks are available. ( free )

    for each tablespace (total) = ( used ) + ( free )

    for every datafile in you tablespace you lose 1 block that's used as the datafile header. ( in dba_data_files blocks - user_blocks = 1 )

    Hope this helps
    Gert

  3. #3
    Join Date
    Aug 2000
    Posts
    236
    To awnser your first query:

    1. SCN is assigned after a transaction is comitted.
    2. To achieve read consistency, Oracle will check the latest SCN and display data only upto the stage of that commit.
    Because, another user might have changed data after that SCN which has still not been comitted and the data blocks might have uncomitted data. But the rollback will have the original of that data after the comitted SCN.

    Hope this clarifies.

    Nizar

  4. #4
    Join Date
    Oct 2000
    Posts
    23
    thank you all

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width