On 21 March 2010 20:43, Daniel Verite <daniel@manitou-mail.org> wrote:
> Sergey Konoplev wrote:
>
>> What about PL/pgSQL wrapper function for CREATE DATABASE with database
>> name check and SECURITY DEFINER option.
>
> Not possible because CREATE DATABASE can't be executed within a function (nor
> within a transaction).
Ah, exactly. Well than what if we use PL/Python or PL/Perl function
where we do connect to this postgres server and do CREATE DATABASE?
Looks very tricky but seems to be working.
--
Sergey Konoplev
Blog: http://gray-hemp.blogspot.com / Linkedin:
http://ru.linkedin.com/in/grayhemp
JID/GTalk: gray.ru@gmail.com / Skype: gray-hemp / ICQ: 29353802