Re: Questions about Rollback - after insert, update,

Поиск
Список
Период
Сортировка
От Emi Lu
Тема Re: Questions about Rollback - after insert, update,
Дата
Msg-id 433316D7.8060506@cs.concordia.ca
обсуждение исходный текст
Ответ на Re: Questions about Rollback - after insert, update,  (Scott Marlowe <smarlowe@g2switchworks.com>)
Список pgsql-general
If ibatis can catch the exception in the program, rollback will work
fine. Could the failure of the transaction in ibatis because of the
network lost or tomcat server shutting down during the procedure.


For instance, in java program

set autocommit = false;
startTranaction
  insert ...              // step1
  update ...            //step2

  /* Error */
  Network lost to DB server or Tomcat server unexceptly shutting down?

  delete          //step3
commitChanges;

Could it because of the communication interrupt between the Web Server
and DB server during the atomic transaction? As a result, step1 & step2
runs successfully in Database, while step3 failed. Also, rollback failed?



>On Thu, 2005-09-22 at 14:59, Emi Lu wrote:
>
>
>>We are using (struts) ibates to run the transaction. We already setup
>>autocommitte = false, and put insert, update, delete into one
>>transaction. However, we found data were not rollback successfully.
>>Moreover, in our atomic transaction, some operations are not finished
>>successfull, but the data are not rollback.
>>
>>Your inputs are very welcomed!
>>
>>
>
>I would tend to think it's either a bug in struts or jdbc or you're
>making some mistake somewhere.  I'm not familiar with struts and
>postgresql together.
>
>You might try logging ALL your SQL statements and seeing what is
>actually being sent back and forth between struts / java and postgresql.
>
>Not sure what else to do, as I use libpq to access postgresql, meaning
>no layer between my app and pgsql, like with jdbc / struts.
>
>---------------------------(end of broadcast)---------------------------
>TIP 6: explain analyze is your friend
>
>


В списке pgsql-general по дате отправления:

Предыдущее
От: Guy Fraser
Дата:
Сообщение: Re: array_dims array_lower/upper distance
Следующее
От: Tony Wasson
Дата:
Сообщение: Getting the amount of overlap when using OVERLAPS