Transaction question

Started by Fredy Ramirezover 22 years ago2 messagesgeneral
Jump to latest
#1Fredy Ramirez
formateli@cantv.net

Hi, I have a question about transactions.

I am developing a Postgresql client.

If I start a transaction in a Postgresql client code, and in this
process a trigger is executed. Are all the processes within the trigger
in the transaction too?

Thank you

P.D. Sorry for my English.

#2Bruce Momjian
bruce@momjian.us
In reply to: Fredy Ramirez (#1)
Re: Transaction question

Fredy Ramirez wrote:

Hi, I have a question about transactions.

I am developing a Postgresql client.

If I start a transaction in a Postgresql client code, and in this
process a trigger is executed. Are all the processes within the trigger
in the transaction too?

Yes, the trigger is in the same transaction as the statement that
triggered it.

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073