1. Get rid of all advertisements and get unlimited access to documents by upgrading to Premium Membership. Upgrade to Premium Now and also get a Premium Badge!

rowid

Discussion in 'SQL PL/SQL' started by monkey, Jun 7, 2014.

  1. monkey

    monkey Long Term Member

    Messages:
    156
    Likes Received:
    0
    Trophy Points:
    230
    Hello!
    What would be the first row's address and the last one's?

    Many thanks!
     
  2. monkey

    monkey Long Term Member

    Messages:
    156
    Likes Received:
    0
    Trophy Points:
    230
  3. ocprep

    ocprep Forum Advisor

    Messages:
    277
    Likes Received:
    76
    Trophy Points:
    410
    Location:
    Orlando, Florida
    That example is simply indicating that it is possible to create a table with an explicitly-defined column that has a data type of ROWID and populate it with a ROWID value. Every table in Oracle has an implicitly defined ROWID column that always contains the location of the row. An explicitly-defined column could contain the ROWID of a different row in the database.

    Theoretically I suppose you could use this to make one row point to the ROWID of a related row in the database -- either in the same table or a different one. It might allow for faster access than a foreign key since no index access would be required. The work to maintain it would probably outweigh any benefits, though.
     
    monkey likes this.