Re: How to get latest inserted record in a table

"Coombs, Earl" <[email protected]>
Newsgroups gmane.comp.db.oracle.devel
Message-ID <LYRIS-1796914-779434-2002.11.26-14.10.45--gcdod-oracle#[email protected]>
Hi Thomas,
Searching AskTom's archives, I find that rowids are unique to table, and I
have seen the row number increment in lock-step with the time of insert;
i.e. insert a record, commit, rowid row number (RRR) = AAb; insert next
record, commit, rowid row number = AAc etc.  (Ref Oracle8i Concepts Part
Number A76965-01 Chapter 12 - Extended Rowids)
Earl

-----Original Message-----
From: Thomas Gaines [mailto:[email protected]]
Sent: Monday, November 25, 2002 1:41 AM
To: Oracle
Subject: [oracle] Re: How to get latest inserted record in a table


Bijus -

You are way, way, way, way off in regard to the use of a rowid to get any
information
about the timestamp associated with a particular row of data.  If Tom
Kyte, the author of the wonderful Wrox Press book "Expert One on One:
Oracle"
was lurking in this forum,
he'd surely lash you with a wet noodle.  To record a date and time, the
values must be recorded in the data.  There's no way to deduce
this information from the location in a block where the data is stored.

Sridhar, you didn't mention the version of Oracle that you're dealing with.
Oracle9i
certainly does record times down to the millisecond level and beyond.  Check
it
out if you're not currently running Oracle9i.

If you're still with Oracle8i or an earlier version, then you must add an
additional
column if you wish to record a fraction of a full second.  You didn't tell
how (or if,
even) you plan to compute these fractional parts of a second.  If that's
still a question,
take a look at the dbms_utility.gettime function.  Perhaps it can play a
role in
your system.

Tom

> 
> I think u can use the rowid concepts..I can't understand ur problem. When
u 
> r talking with out using DML operations........
> Any way there is some way with rowid check it up ....
> Thanx
> Bijus
 
 
 
---
Change your mail options at http://p2p.wrox.com/manager.asp or 
to unsubscribe send a blank email to %%email.unsub%%.


---
Change your mail options at http://p2p.wrox.com/manager.asp or 
to unsubscribe send a blank email to [email protected].
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.