"Louth, William (Exchange)" wrote:

> Would they really write to the database more often, this seems like a real
> performance overhead. Its bad enough that some containers do not even
> support tuned writes never mind this. I really cannot imagine a reason for
> this especially since the bean could be updated many times during a
> transaction with each changes ending up with a sql call.
>

I can imagine some reasons :
- you want to be able to read uncommitted data
- the update order is not respected with commit-at-end-of-tx, and you have
constraints set in your DB (example : suppose you create a book and an author in
the same tx, and that the book contains a foreign key pointing to the new
author. If there is a constraint in your DB that the author key must exist, and
if the book is inserted first, you will have an error. Instead, if the author is
inserted first, no problem.)

JB.

>
> William
>
> > -----Original Message-----
> > From: Stu Halloway [SMTP:[EMAIL PROTECTED]]
> > Sent: Monday, February 21, 2000 8:07 PM
> > To:   [EMAIL PROTECTED]
> > Subject:      Re: trying to come up with a design pattern to solve
> > acommonJ2EE problem
> >
> > > It won't be in the database because the transaction has not yet
> > > completed, thus the EJB server has not yet committed the changes. (EJB
> > > users write-at-commit)
> >
> > Maybe, maybe not.  EJB server can write to the database more often than
> > that.  Vendor's option.
> >
> > > Changes made to the database are visible immediately in the same
> > > transaction.
> >
> > I believe that this is database-vendor-specific, and might not always be
> > true.  (Although it is the behavior I have always seen.)
> >
> > Stuart Halloway
> > DevelopMentor
> > http://www.develop.com/hp/halloway
> >
> > ==========================================================================
> > =
> > To unsubscribe, send email to [EMAIL PROTECTED] and include in the
> > body
> > of the message "signoff EJB-INTEREST".  For general help, send email to
> > [EMAIL PROTECTED] and include in the body of the message "help".
>
> ***********************************************************************
> Bear Stearns is not responsible for any recommendation, solicitation,
> offer or agreement or any information about any transaction, customer
> account or account activity contained in this communication.
> ***********************************************************************
>
> ===========================================================================
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff EJB-INTEREST".  For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".

--
Jean-Baptiste Nizet
[EMAIL PROTECTED]

R&D Engineer, S1 Belgium
Excelsiorlaan 87
B-1930 Zaventem
+32 2 714 45 42

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to