
> > > Are there many applications which have many SELECT statements(without
> > > FOR UPDATE) in one tx ?
> >
> > Why not ?
> >
> It seems to me that multiple SELECT statements in a tx has little
> meaning unless the tx is executed in SERIALIZABLE isolation level.

E.g. a table is accessed multiple times to select different data
in an inner application loop. No need for serializable here.

Andreas

Tue, 24 Oct 2000 11:18:26 +0200
Zeugswetter Andreas SB <ZeugswetterA@wien.spardat.at>
AW: BLERe: AW: AW: relation ### modified while in use


Zeugswetter Andreas SB wrote:

> > > > Are there many applications which have many SELECT statements(without
> > > > FOR UPDATE) in one tx ?
> > >
> > > Why not ?
> > >
> > It seems to me that multiple SELECT statements in a tx has little
> > meaning unless the tx is executed in SERIALIZABLE isolation level.
>
> E.g. a table is accessed multiple times to select different data
> in an inner application loop. No need for serializable here.
>

And seems no need to execute in one tx.
Hmm,we seems to be able to call a cleanup procedure
internally which is equivalent to 'commit' after each
consecutive read-only statement.  Is it a problem ?

Regards.
Hiroshi Inoue


Tue, 24 Oct 2000 18:31:07 +0900
Hiroshi Inoue <Inoue@tpf.co.jp>
Re: AW: BLERe: AW: AW: relation ### modified while in use
Hello,
anyone thought about implementing two-phase commit to
be able to support distributed transactions ?
I have no clue how complex it would be, someone knows ?

devik



Tue, 24 Oct 2000 13:52:38 +0200
devik@cdi.cz
Two-phase commit


Philip Warner wrote:

> At 18:31 24/10/00 +0900, Hiroshi Inoue wrote:
> >
> >
> >Zeugswetter Andreas SB wrote:
> >
> >> > > > Are there many applications which have many SELECT statements(without
> >> > > > FOR UPDATE) in one tx ?
> >> > >
> >> > > Why not ?
> >> > >
> >> > It seems to me that multiple SELECT statements in a tx has little
> >> > meaning unless the tx is executed in SERIALIZABLE isolation level.
> >>
> >> E.g. a table is accessed multiple times to select different data
> >> in an inner application loop. No need for serializable here.
> >>
> >
> >And seems no need to execute in one tx.
> >Hmm,we seems to be able to call a cleanup procedure
> >internally which is equivalent to 'commit' after each
> >consecutive read-only statement.  Is it a problem ?
>
> I have not followed the entire thread, but if you are in a serializable OR
> repeatable-read transaction, I would think that read-only statements will
> need to keep some kind of lock on the rows they read (or the table).
>

Currently read-only statements keep AccessShareLock on the table
(not on the rows) until the end of the statement and none objects
to it.  What we've discussed is whether we should keep the lock
until the end of tx or not in read committed mode.

Regards.
Hiroshi Inoue


Wed, 25 Oct 2000 15:40:49 +0900
Hiroshi Inoue <Inoue@tpf.co.jp>
Re: AW: BLERe: AW: AW: relation ### modified whilein use
At 18:31 24/10/00 +0900, Hiroshi Inoue wrote:
>
>
>Zeugswetter Andreas SB wrote:
>
>> > > > Are there many applications which have many SELECT statements(without
>> > > > FOR UPDATE) in one tx ?
>> > >
>> > > Why not ?
>> > >
>> > It seems to me that multiple SELECT statements in a tx has little
>> > meaning unless the tx is executed in SERIALIZABLE isolation level.
>>
>> E.g. a table is accessed multiple times to select different data
>> in an inner application loop. No need for serializable here.
>>
>
>And seems no need to execute in one tx.
>Hmm,we seems to be able to call a cleanup procedure
>internally which is equivalent to 'commit' after each
>consecutive read-only statement.  Is it a problem ?

I have not followed the entire thread, but if you are in a serializable OR
repeatable-read transaction, I would think that read-only statements will
need to keep some kind of lock on the rows they read (or the table).


----------------------------------------------------------------
Philip Warner                    |     __---_____
Albatross Consulting Pty. Ltd.   |----/       -  \
(A.B.N. 75 008 659 498)          |          /(@)   ______---_
Tel: (+61) 0500 83 82 81         |                 _________  \
Fax: (+61) 0500 83 82 82         |                 ___________ |
Http://www.rhyme.com.au          |                /           \|
                                 |    --________--
PGP key available upon request,  |  /
and from pgp5.ai.mit.edu:11371   |/

Wed, 25 Oct 2000 16:47:40 +1000
Philip Warner <pjw@rhyme.com.au>
Re: AW: BLERe: AW: AW: relation ### modified while
  in use