From: | William Leite Araújo <william(dot)bh(at)gmail(dot)com> |
---|---|
To: | "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-bugs(at)postgresql(dot)org |
Subject: | Re: BUG #2372: dblink_exec doesn't return. NEVER! |
Date: | 2006-04-03 21:38:09 |
Message-ID: | bc63ad820604031438j23ece340p6dfcab7a1add90f5@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
I need this to give a credit from canceled billets.
But anyone instead of roots can insert on this table.
If it's done by a function, only roots must run it. So, the trigger
will fail because is runned a no "su"...
On 4/3/06, Stephen Frost <sfrost(at)snowman(dot)net> wrote:
>
> * Tom Lane (tgl(at)sss(dot)pgh(dot)pa(dot)us) wrote:
> > dblink connections to your own database are very seldom a good idea;
> > there is always a better, more efficient, less deadlock-prone way
> > to do it. In this case I'd venture that you want to use a SECURITY
> > DEFINER function, and not dblink at all.
>
> The one case I've seen where people are trying to do this is where they
> want to provide some kind of notification or log to a table to be
> visible prior to the current transaction actually committing. I can see
> how this could be useful for long-running transactions or function calls
> (It'd actually be useful in some of the work I've been doing, but we've
> worked around it by providing NOTICE's when we're debugging and
> splitting the long running function into multiple function calls when we
> want more fine-grained information about where we're at in the process
> for users to view).
>
> Thanks,
>
> Stephen
>
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.2 (GNU/Linux)
>
> iD8DBQFEMZPKrzgMPqB3kigRAkjsAJwJjASObN0lMkuO8w5qbolAxOImlACfTjJ4
> HNN2dVp6S6ng5Fc9yIsxGSE=
> =akx8
> -----END PGP SIGNATURE-----
>
>
>
--
William Leite Araújo
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2006-04-03 21:48:27 | Re: BUG #2372: dblink_exec doesn't return. NEVER! |
Previous Message | Stephen Frost | 2006-04-03 21:29:46 | Re: BUG #2372: dblink_exec doesn't return. NEVER! |