Re: Reference pg_user ?

From: "Joel Burton" <joel(at)joelburton(dot)com>
To: "Carsten Zerbst" <carsten(dot)zerbst(at)atlantec-es(dot)com>, <pgsql-general(at)postgresql(dot)org>
Subject: Re: Reference pg_user ?
Date: 2002-03-19 18:04:24
Message-ID: JGEPJNMCKODMDHGOBKDNKEOBCFAA.joel@joelburton.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

You can use a one-to-one table (as you are trying); you can use an inherited
table.

In either case, tho', pg_shadow is the user table; pg_user is a view that
hides the password column.

Joel BURTON | joel(at)joelburton(dot)com | joelburton.com | aim: wjoelburton
Knowledge Management & Technology Consultant

> -----Original Message-----
> From: pgsql-general-owner(at)postgresql(dot)org
> [mailto:pgsql-general-owner(at)postgresql(dot)org]On Behalf Of Carsten Zerbst
> Sent: Tuesday, March 19, 2002 10:33 AM
> To: pgsql-general(at)postgresql(dot)org
> Subject: [GENERAL] Reference pg_user ?
>
>
> 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
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Jean-Luc Lachance 2002-03-19 18:07:58 How to create crude report with psql and/or plpgsql
Previous Message Travis Bauer 2002-03-19 17:38:58 PL/PGSQL and PL/Perl time issues