Hello,

I assume you do use JDBC for that insertion - you may make use of
the BatchUpdateException thrown by the executeBatch() method.

The BatchUpdateException actually has a status array for the 
batch execution, which contains Statement.SUCCESS_NO_INFO for
each row succeeded, and has a size that is equal to the number
of rows processed successfully (as processing stops on the 
first failed row).

So, you can skip that next row and try to continue, and so on,
and so use batch execution to speed up a single insertion process
(if the percentage of bad data isn't too large). 

Take note of the fact that if in autocommit mode everything that 
was in the last packet that caused the error is not inserted, so 
you may have to try the next row as single insert, until the 
culprit bad row is found - but this is only for autocommit mode.

If your threads all insert into the same table, they collide
in the insertion process somehow. 

Alexander Schr�der
SAP DB, SAP Labs Berlin 

> -----Original Message-----
> From: poornima ponnuswamy [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, July 16, 2003 4:35 PM
> To: [EMAIL PROTECTED]
> Subject: Decrease the execution time in sapdb-Question
> 
> 
> Hi,
> I was wondering how I can improve the performance in
> SAPDB when inserting a statement. I have used prepared
> statement and for my data I cant use batch statements
> as some data may be wrong and it will affects other
> data in the batch processing. so my best bet is use
> multiple threads each with individual connection and
> it helps to process many files at once. so I have used
> like 8 threads for my program. Is there any feature in
> sapdb that I can use to maximize the perfomance and
> decrease the execution time like setting the
> buffersize or any feature in sapdb that helps.
> Thanks for any suggestion provided,
> poornima
> 
> __________________________________
> Do you Yahoo!?
> SBC Yahoo! DSL - Now only $29.95 per month!
> http://sbc.yahoo.com
> _______________________________________________
> sapdb.general mailing list
> [EMAIL PROTECTED]
> http://listserv.sap.com/mailman/listinfo/sapdb.general
> 
_______________________________________________
sapdb.general mailing list
[EMAIL PROTECTED]
http://listserv.sap.com/mailman/listinfo/sapdb.general

Reply via email to