Changing DB ownership

From: Christopher Murtagh <christopher(dot)murtagh(at)mcgill(dot)ca>
To: postgres general <pgsql-general(at)postgresql(dot)org>
Subject: Changing DB ownership
Date: 2003-07-30 13:30:06
Message-ID: 1059571805.966.8.camel@mafalda.murtagh.name
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Dumb question maybe, but how does one change database ownership? I've
tried several permutations of:

ALTER DATABASE SET ("|'| )owner("|'| ) TO ("|'| )newowner("|'| );

and I tried looking at pg_database and I *was* able to hack this (got a
clue half way through writing this email... sorry):

UPDATE pg_database SET datdba = 504 WHERE datname='chris';

And that worked as expected, but I'm worried that I might have missed
something somewhere else. Will the above UPDATE cause problems down the
road?

Any info/clue would be much appreciated. Thanks in advance.

Cheers,

Chris

Responses

Browse pgsql-general by date

  From Date Subject
Next Message EDMUND DENGLER 2003-07-30 13:49:54 Re: Unused Indexes
Previous Message DeJuan Jackson 2003-07-30 13:26:40 Re: Unused Indexes