Re: pgsql functions and transactions?
От | Josh Berkus |
---|---|
Тема | Re: pgsql functions and transactions? |
Дата | |
Msg-id | 200408262146.01453.josh@agliodbs.com обсуждение исходный текст |
Ответ на | pgsql functions and transactions? (Betsy Barker <betsy.barker@supportservicesinc.com>) |
Список | pgsql-novice |
Betsy, > I read the posts on pgsql functions and transactions from the Novice list, > and I think they are saying "PGSQL functions do not support transactions". > Is this correct? Or is the idea that functions are automatically in a > transaction? That's right. Soon (8.0 or 8.1) functions will support *sub-transactions*, or savepoints, but that still won't do a checkpoint and synch, which is what you need. In my experience, there is a limit to the amount of processing you can reasonably do in a single function in Postgres because of the need to stop and synch (and possibly VACUUM). I often have "series" of functions (in one case, about 18) which are executed in succession by a Perl script. We've been discussing PROCEDURES on -hackers which are non-transactional (and thus can contain several transactions). But nobody is coding this yet. -- Josh Berkus Aglio Database Solutions San Francisco
В списке pgsql-novice по дате отправления: