db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleg Nitz <on@ukr.net> (by way of Oleg Nitz ...@ukr.net>)
Subject Re: [batch modus] additional failures/errors
Date Fri, 17 Jan 2003 00:25:14 GMT
Hi Armin,

On Wednesday 15 January 2003 16:37, you wrote:
> think there is another problem with the batch
> mode. Say you set bachMode 'true' and then
> close the PB instance.
> Then you obtain a PB from the PBF what
> batchMode have this this instance? Maybe
> you get another instance with batchMode 'false'.
> Thus I propose to set batchMode explicit to 'false'
> when PB.close() was called and we use the

Better to batchMode attribute in jdbc-connection-descriptor

> batchMode attribute in jdbc-connection-descriptor
> as a switch to allow batch updates or not, independently
> if the database supports batch updates.

I don't understand you here. If database doesn't support batch updates, how
can we use batch updates if the attribute is set to 'true'?

> Another question:
> say we have 10 products and do the following
> pseudo code with PB-api
>
> broker.beginTx
> create 2 products
> store the products
> list = get all products
> broker.commit
>
> with batchMode 'true' list will contain 50 products,
> without 52.

Yes, this is the price for the batch mode.

> Or does the database-driver/batch-connection
> a auto-flush (executeBatch()) when a 'select' query was
> done when running in batch mode to assure data-integrity?

No. But there are no problems with data-integrity: the changes are flushed to
the databases no commit, as in ODMG, and OJB user just should be aware of
that.

Regards,
 Oleg


Mime
View raw message