Re: Ora2pg.pl - some feedback

From: <pgsql-general(at)commandprompt(dot)com>
To: Susan Lane <suel(at)dpn(dot)com>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: Ora2pg.pl - some feedback
Date: 2001-08-10 20:06:39
Message-ID: Pine.LNX.4.30.0108101304460.24954-100000@commandprompt.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Fri, 10 Aug 2001, Susan Lane wrote:
>Question - is there a way to change the owner of a postgres database after
>it's been created? I know I can alter table info, but is there something
>to do this for the db?

Look at the pg_database system catalog. Specifically, the datdba column.
It should be the PostgreSQL UID of the user who owns it.

For example:

lx=# SELECT datname, datdba FROM pg_database
lx-# INNER JOIN pg_user ON (datdba=usesysid);
datname | datdba
--------------+--------
postgres | 507
twig2 | 501
template0 | 507

Regards,
Jw.
--
jlx(at)commandprompt(dot)com by way of pgsql-general(at)commandprompt(dot)com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message pgsql-general 2001-08-10 20:09:25 Re: Ora2pg.pl - some feedback
Previous Message Sean Chittenden 2001-08-10 19:59:27 Re: Slightly OT: Open Source database design tool?