CREATE USER in RULE or TRIGGER

Started by Marcin Mazurekover 25 years ago2 messagesgeneral
Jump to latest
#1Marcin Mazurek
M.Mazurek@poznan.multinet.pl

HI,
is it possible to CREATE USER in a RILE or TRIGGER? I haven't succeded so
far, although the TRIGGER and RULE is damn simple.
I thought it some limitation I'm not aware of.
If it is what's the other way to do it with trigger function. C function
with SPI?

tia
mazek

Marcin Mazurek

--
Kierownik Dzia�u Systemowego
MULTINET SA o/Poznan
http://www.multinet.pl/

#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Marcin Mazurek (#1)
Re: CREATE USER in RULE or TRIGGER

Marcin Mazurek <M.Mazurek@poznan.multinet.pl> writes:

is it possible to CREATE USER in a RILE or TRIGGER?

Not with a rule, and not with a plpgsql trigger either (although I think
the latter restriction is fixed in current sources). You could make it
work with a pltcl trigger, I believe.

regards, tom lane