You're right.  I said I'd never actually implemented it.  ; )  You'd have to
use a semaphore in the DB to lock it, and that gets nasty fast.  Yeah,
anyway, back to what I said at the beginning: just use the DB's
autonumbering capabilities.

barneyb

> -----Original Message-----
> From: Jochem van Dieten [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, January 06, 2004 10:57 AM
> To: CF-Talk
> Subject: Re: CF_MAX_ID - MySQL slowww
>
> Barney Boisvert wrote:
> >> But you need Atomicity and/or Isolation (reading the last value
> >> and incrementing it are 2 different actions that need to be
> >> somehow grouped), so you still need a transaction. But if you go
> >> for a HEAP table which you build on application start, the
> >> overhead should be far less.
> >
> > The atomicity and isolation comes from the application-side
> lock.  In
> > effect, that function becomes single threaded, and since
> that's the ONLY
> > access to the table, there needn't be any transactional
> logic on the DB
> > side.
>
> cflock is only instance wide.
>
> Jochem
>
> --
> I don't get it
> immigrants don't work
> and steal our jobs
>      - Loesje
>
>
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to