Re: global context instead of for update or another idea ?

From: <fitzjarrell_at_cox.net>
Date: Fri, 5 Sep 2008 05:47:45 -0700 (PDT)
Message-ID: <7de20a52-4f45-4dd1-8e46-998a867c2c50@k30g2000hse.googlegroups.com>


Comments embedded.
On Sep 5, 2:43 am, hopehope_123 <hopehope_..._at_yahoo.com> wrote:
> Hi ,
>
> is it possible to use global variables  in oracle? and is there any
> way  to  control concurrency  on this  memory variable?
>

Why?

> i can use a  table,  and  read this  by using for update.  Under heavy
> loads,  this will create contention.
>

What is it you're doing that 'requires' this?

> what else can i do?
>
> i try to use sequence data variable.   there are multiple sessions.
> when  one session  reads  next value,  others  must wait ,

No, they don't.

>  and  this
> creates contention also.

Not in my experience.

> and  i need to  use  reuse  values  so
> sequence does not allow to use older values.
>

Certainly it does, this is precisely why there is a CURRVAL call to a sequence, to reuse the current value over and over and over and over again.

>  synchronized methods of java  do the same  thing ,  can i do
> similiar thing  in oracle? does global context  provide  this type of
> funcionality?
>

We need to know why you think you 'need' such a crutch. You'll need to explain in far more detail.

> kind regards,
> hope

David Fitzjarrell Received on Fri Sep 05 2008 - 07:47:45 CDT

Original text of this message