pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: jwieck@debis.com
To: brandtwr-pgsql@draaw.net
Cc: pgsql-sql@postgreSQL.org
Subject: Re: [SQL] change username
Date: Mon, 28 Dec 1998 21:19:59 +0100 (MET)
Message-ID: <m0zuj8x-000EBPC@orion.SAPserv.Hamburg.dsh.de> (raw)
In-Reply-To: <19981228131503.01192@draaw.net>

> 
> I have a user on my system whose username has recently changed.  The user
> owns and is a non-owning user of multiple database.  I have tried a command
> of the form:
> 
> update pg_user set usename='newname' where usesysid=###;
> 
> When I try this I get an error.  Does anyone know how to change this
> information?  If I delete the user and recreate the user with the same uid
> does that retain all the existing database permissions?

    pg_user is a system view. Update pg_shadow instead.

    But what error do you get? The command should respond with
    "UPDATE 0" and do nothing!


Jan

-- 

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#======================================== jwieck@debis.com (Jan Wieck) #




view thread (3+ messages)  latest in thread

Message-ID: <m0zuj8x-000EBPC@orion.SAPserv.Hamburg.dsh.de>
Permalink:  ../m0zuj8x-000EBPC@orion.SAPserv.Hamburg.dsh.de/
Also on:    postgresql.org/message-id/m0zuj8x-000EBPC@orion.SAPserv.Hamburg.dsh.de

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: jwieck@debis.com, brandtwr-pgsql@draaw.net
  Subject: Re: [SQL] change username
  In-Reply-To: <m0zuj8x-000EBPC@orion.SAPserv.Hamburg.dsh.de>
  References: <19981228131503.01192@draaw.net> <m0zuj8x-000EBPC@orion.SAPserv.Hamburg.dsh.de>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox