Re: SET Role doesn't work from Security Definer Function... - Mailing list pgsql-general

From Alvaro Herrera
Subject Re: SET Role doesn't work from Security Definer Function...
Date
Msg-id 20100223150639.GD3672@alvh.no-ip.org
Whole thread Raw
In response to Re: SET Role doesn't work from Security Definer Function...  (dipti shah <shahdipti1980@gmail.com>)
Responses Re: SET Role doesn't work from Security Definer Function...
List pgsql-general
dipti shah escribió:

> For your reference I did something like this:
>
> 1. Create Function foo1 .... (this is without SECURITY DEFINER where I am
> using SET ROLE to current user).
>
> 2. Create Function foo2 with SECURITY DEFINER ...
>          spi_exe_query("select foo1()"); ==> Here it throws the error.

Shouldn't it be the other way around?  The normal function calls the
security-definer one.

--
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

pgsql-general by date:

Previous
From: Stefan Schwarzer
Date:
Subject: Re: Subqueries or Joins? Problems with multiple table query
Next
From: Tom Lane
Date:
Subject: Re: pg_dump new version