Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Retrieving records in order they were placed.

Re: Retrieving records in order they were placed.

From: Doug Cowles <dcowles_at_bigfoot.com>
Date: Wed, 14 Jul 1999 17:14:43 -0400
Message-ID: <378CFDC3.D1F59E2D@bigfoot.com>


How can you get granularity to 1/1000 of a second? I thought Oracle Date files lowest level of granularity was a second? - Dc.

Mark G wrote:

> Why don't you build on some of your ideas.
>
> Define 'very very high' number of transactions. A sequence can get to a
> very high value before it raps (sorry Wraps, no Will Smith here!), set it to
> something ridiculousy high.
>
> Instead of bouncing the machine, why don't you have a job (DBMS_JOB) to drop
> the sequence and rebuild, starting with 1. The job could be set to run
> whenever you want it.
>
> Also timestamps. I know you are inserting records in quick succession but
> you can try detecting timestamps down to 1/1000th of a second.
>
> Or combine the two, timestamps and sequences. That way, if the sequence
> wraps, the timespamp will be well ahead of itself.
>
> Hope one of these ideas inspires you!
>
> M
>
> b_rich2_at_my-deja.com wrote in message <7m4rcj$9gd$1_at_nnrp1.deja.com>...
> >I have to put records into a table, and later retrieve them in the order
> >in which they were placed. I have a very very large number of entries to
> >be placed in a live system. The records are logs of important events in
> >the system.
> >
> >My first thought was to use the unix time stamp to place as the field to
> >order on, but there will probably be many entries entered in rapid
> >succession. Thus many entries could be entered at the same time stamp
> >interval.
> >
> >I then though of having a sequence number associated with each record,
> >increasing one by one with each record stored. This will work well until
> >the sequence numbers begin to wrap. If they are retrieved in order of
> >sequence number, and then they wrap, the records entered after the wrap
> >(sequences 1,2,3,4 etc) will all of a sudden be pulled out before the
> >earlier records with high sequence numbers.
> >
> >Another idea is to just use the sequence numbers, and re-boot the box
> >every few weeks when the sequence numbers get high, but this is really
> >unacceptable in the environment where this will be run.
> >
> >Does anyone know how to get around this problem? Any help would be
> >GREATLY appreciated.
> >
> >
> >Sent via Deja.com http://www.deja.com/
> >Share what you know. Learn what you don't.
Received on Wed Jul 14 1999 - 16:14:43 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US