From: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> |
---|---|
To: | Carsten Zerbst <carsten(dot)zerbst(at)atlantec-es(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: Reference pg_user ? |
Date: | 2002-03-19 16:08:51 |
Message-ID: | 200203191608.g2JG8pW29449@candle.pha.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
The problem here is that pg_user is a view, not a real table. You can
use pg_shadow, but that can only be read by super-users. Not sure if
that is a solution.
---------------------------------------------------------------------------
Carsten Zerbst wrote:
> Hello,
>
> I need users and groups for an application and thought about
> using ordinary postgres users and groups.
>
> But I need some additional information like name, email-addres and the
> like, so i tried to use something like:
>
> test=# create table users (
> test(# shortname name references pg_user,
> test(# lastname varchar not null,
> test(# email varchar not null
> test(# );
> NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY
> check(s)
> ERROR: Referenced relation "pg_user" is not a table
> NOTICE: CREATE TABLE will create implicit trigger(s) for FOREIGN KEY
> check(s)
> ERROR: Referenced relation "pg_user" is not a table
>
> Is it somehow possible to reference the system catalog with
> the users ?
>
> Thanks, Carsten
>
> --
> Dipl. Ing. Carsten Zerbst | carsten(dot)zerbst(at)atlantec-es(dot)com
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/users-lounge/docs/faq.html
>
--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026
From | Date | Subject | |
---|---|---|---|
Next Message | Herbert Liechti | 2002-03-19 16:09:44 | Re: Visual display tool? |
Previous Message | Peter Peltonen | 2002-03-19 15:59:29 | pq_recvbuf: unexpected EOF on client connectoin |