Re: pg_stat_database shows userid as OID

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>
Cc: Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pg_stat_database shows userid as OID
Date: 2002-11-17 18:16:29
Message-ID: 1629.1037556989@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl> writes:
> In the pg_stat_activity view, the usesysid is shown as having type Oid.
> However pg_shadow says it's an integer. Is there a reason?

There's been disagreement for a long time over whether userids should be
OIDs or ints. If you want to introduce consistency then it's going to
take a lot more than a one-line patch. (First you'll need to convince
the partisans involved which answer is the right one.)

> Looks like a bug.

Not as long as OID is 4 bytes.

I'd recommend not making any piecemeal changes, especially not when
there's not yet a consensus which way to converge.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2002-11-17 18:25:23 Re: btree shrinking again
Previous Message Patrick Welche 2002-11-17 16:57:21 Re: Debian build prob

Browse pgsql-patches by date

  From Date Subject
Next Message Bruno Wolff III 2002-11-17 19:46:52 7.4 cube patch to add create cast
Previous Message Bruno Wolff III 2002-11-17 17:38:07 Re: 7.4 patch for cube to handle extra_float_digits