Re: 8.0 -> 8.1 migration issue with ROLEs ... maybe? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: 8.0 -> 8.1 migration issue with ROLEs ... maybe?
Date
Msg-id 5333.1132790726@sss.pgh.pa.us
Whole thread Raw
In response to 8.0 -> 8.1 migration issue with ROLEs ... maybe?  ("Marc G. Fournier" <scrappy@postgresql.org>)
List pgsql-hackers
"Marc G. Fournier" <scrappy@postgresql.org> writes:
> template1=# create user a_test_group in group a_test_group;
> ERROR:  role "a_test_group" already exists

> So, if I have a group that happens to have a userid matching it, in the 
> old system, its going to fail to load?

Groups and users are the same thing now, so the above isn't unexpected.
I think though that if you just ignore the error, it'll still work the
way you want --- the same role can serve as both a user and a group.

If the script tries to create the group first, you might needALTER USER a_test_group LOGIN;
to enable the role to login as a user.
        regards, tom lane


pgsql-hackers by date:

Previous
From: "Marc G. Fournier"
Date:
Subject: 8.0 -> 8.1 migration issue with ROLEs ... maybe?
Next
From: Christopher Kings-Lynne
Date:
Subject: Re: MS SQL Server compatibility functions