![]() | |
![]() |
| | Thread Tools | Display Modes |
#11
| |||
| |||
|
|
begin Vesa-Matti Kari schrieb: Hello! I need to do SELECT and DELETE as a single atomic operation. Is it possible to use transactions in Postgresql PL/Perl functions? If yes, how? Any pointers would be appreciated. Thanks! Sure. A function, also a pl/perl - function, runs within a transaction. But you can't do a 'begin' ... 'commit;' within the function. Simply write your function and call it, it's an atomic transaction. |
#12
| |||
| |||
|
|
begin Vesa-Matti Kari schrieb: Hello! I need to do SELECT and DELETE as a single atomic operation. Is it possible to use transactions in Postgresql PL/Perl functions? If yes, how? Any pointers would be appreciated. Thanks! Sure. A function, also a pl/perl - function, runs within a transaction. But you can't do a 'begin' ... 'commit;' within the function. Simply write your function and call it, it's an atomic transaction. |
#13
| |||
| |||
|
|
begin Vesa-Matti Kari schrieb: Hello! I need to do SELECT and DELETE as a single atomic operation. Is it possible to use transactions in Postgresql PL/Perl functions? If yes, how? Any pointers would be appreciated. Thanks! Sure. A function, also a pl/perl - function, runs within a transaction. But you can't do a 'begin' ... 'commit;' within the function. Simply write your function and call it, it's an atomic transaction. |
#14
| |||
| |||
|
|
begin Vesa-Matti Kari schrieb: Hello! I need to do SELECT and DELETE as a single atomic operation. Is it possible to use transactions in Postgresql PL/Perl functions? If yes, how? Any pointers would be appreciated. Thanks! Sure. A function, also a pl/perl - function, runs within a transaction. But you can't do a 'begin' ... 'commit;' within the function. Simply write your function and call it, it's an atomic transaction. |
#15
| |||
| |||
|
|
begin Vesa-Matti Kari schrieb: Hello! I need to do SELECT and DELETE as a single atomic operation. Is it possible to use transactions in Postgresql PL/Perl functions? If yes, how? Any pointers would be appreciated. Thanks! Sure. A function, also a pl/perl - function, runs within a transaction. But you can't do a 'begin' ... 'commit;' within the function. Simply write your function and call it, it's an atomic transaction. |
#16
| |||
| |||
|
|
begin Vesa-Matti Kari schrieb: Hello! I need to do SELECT and DELETE as a single atomic operation. Is it possible to use transactions in Postgresql PL/Perl functions? If yes, how? Any pointers would be appreciated. Thanks! Sure. A function, also a pl/perl - function, runs within a transaction. But you can't do a 'begin' ... 'commit;' within the function. Simply write your function and call it, it's an atomic transaction. |
#17
| |||
| |||
|
|
begin Vesa-Matti Kari schrieb: Hello! I need to do SELECT and DELETE as a single atomic operation. Is it possible to use transactions in Postgresql PL/Perl functions? If yes, how? Any pointers would be appreciated. Thanks! Sure. A function, also a pl/perl - function, runs within a transaction. But you can't do a 'begin' ... 'commit;' within the function. Simply write your function and call it, it's an atomic transaction. |
![]() |
| Thread Tools | |
| Display Modes | |
| |