Re: Must be owner of function

Поиск
Список
Период
Сортировка
От John R Pierce
Тема Re: Must be owner of function
Дата
Msg-id 4C4F64CE.1010103@hogranch.com
обсуждение исходный текст
Ответ на Must be owner of function  ("Jerry Richards" <jerry.richards@teotech.com>)
Список pgsql-general
  On 07/27/10 3:39 PM, Jerry Richards wrote:
> I am using postgresql-odbc and trying to "CREATE OR REPLACE FUNCTION..."
> from my C-Application, however, I get "must be owner of function ..." error.
> If I execute the command logged in as postgres (i.e. su postgres), then I
> can execute the command.  I think I tried to grant privileges to public for
> the tables/functions I'm using to no avail.  I also tried to alter function
> ownership, but this also gets an error because th function does not exist
> yet.
>
> Any help/guidance would be appreciated.

postgres has seperate privileges at the database level (allow you to
connect), schema (such as public, allow you to see the schema, allow you
to add objects to the schema), and at the object (table, view) level
(grant/deny access, grant/deny update, etc).

also, databases and objects have individual ownership.

for simple applications without special security requirements, I create
the database owned by the user account that will be managing it, like...

     log in as postgres,
         CREATE USER someuser WITH PASSWORD 'whatever';
         CREATE DATABASE somedb OWNED BY someuser;
     log in as someuser,
         CREATE TABLE ....
         CREATE VIEW ...

etc.



В списке pgsql-general по дате отправления:

Предыдущее
От: Patrick May
Дата:
Сообщение: Histogram generator
Следующее
От: Dann Corbit
Дата:
Сообщение: Re: Histogram generator