Re: pgagent in Debian sid

From: Dave Page <dpage(at)pgadmin(dot)org>
To: Seb <spluque(at)gmail(dot)com>
Cc: pgAdmin Support <pgadmin-support(at)postgresql(dot)org>
Subject: Re: pgagent in Debian sid
Date: 2009-06-03 16:24:00
Message-ID: 937d27e10906030924u4795fbe6u8437556da071d857@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support

On Wed, Jun 3, 2009 at 5:05 PM, Seb <spluque(at)gmail(dot)com> wrote:

> It would also be interesting to see the results of those two queries
>> run by hand:
>
>> SELECT cl.oid FROM pg_class cl JOIN pg_namespace ns ON
>> ns.oid=relnamespace WHERE relname='pga_job' AND nspname='pgagent';
>
>> SELECT has_schema_privilege('pgagent', 'USAGE');
>
>
> Ok, if I do those as my normal user the first one goes fine:
>
>
>  oid
> -----
> (0 rows)

No - it should return a row. That means that the schema doesn't exist
in the database you're connected to. The first query should work for
any user, regardless of what permissions you have on the schema
(because the query is looking at the catalogs, not the schema itself).

> Logged in as the postgres user:
>
> postgres=# SELECT cl.oid FROM pg_class cl JOIN pg_namespace ns ON
> postgres-# ns.oid=relnamespace WHERE relname='pga_job' AND nspname='pgagent';
>  oid
> -------
>  46884
> (1 row)

Unfortunately you didn't show the psql prompt when you ran the query
using your normal user account, but I'll bet you're not connecting to
the postgres database like the postgres user is. That would explain
why you can't see the schema, but postgres can.

--
Dave Page
EnterpriseDB UK: http://www.enterprisedb.com

In response to

Responses

Browse pgadmin-support by date

  From Date Subject
Next Message Seb 2009-06-03 16:42:00 Re: pgagent in Debian sid
Previous Message Dave Page 2009-06-03 15:47:49 Re: pgagent in Debian sid