Re: create function (plpgsql): permission denied - Mailing list pgsql-admin

From John Gunther
Subject Re: create function (plpgsql): permission denied
Date
Msg-id 3E9174CD.7000306@bucksvsbytes.com
Whole thread Raw
In response to Re: create function (plpgsql): permission denied  (Pedro Salazar <pedro-b-salazar@ptinovacao.pt>)
Responses Re: create function (plpgsql): permission denied
Re: create function (plpgsql): permission denied
List pgsql-admin
 From psql <databasename> -U<databaseowner>, issue:
    GRANT USAGE ON LANGUAGE plpgsql to <desireduser>;
You may also need (to allow creation of the function)
    GRANT ALL ON SCHEMA <schemaname> TO <desireduser>;

This will grant <desireduser> the usage of plpgsql even if it is untrusted.

For attribute explanations, see
http://www.postgresql.org/docs/view.php?version=7.3&idoc=1&file=catalog-pg-language.htm


John Gunther
Bucks vs Bytes Inc


Pedro Salazar wrote:

>Greetings,
>
>On Mon, 2003-04-07 at 12:39, Pedro Salazar wrote:
>
>
>>select * from pg_language ;
>>lanname | lanispl | lanpltrusted | lanplcallfoid | lanvalidator | lanacl
>>----------+---------+--------------+---------------+--------------+--------
>> plpgsql  | t       | f            |         20893 |            0 |
>>
>>
>
>I updated the 'lanpltrusted' attribute to true, and now I can create
>functions.
>
>But, is it possible that only a group or a specified list of users have
>permission to create plpgsql functions instead trust the language for
>all users?
>
>thanks,
>Pedro Salazar.
>
>


pgsql-admin by date:

Previous
From: Pedro Salazar
Date:
Subject: Re: create function (plpgsql): permission denied
Next
From: Tom Lane
Date:
Subject: Re: create function (plpgsql): permission denied