Index: openacs-4/packages/acs-kernel/sql/postgresql/upgrade/upgrade-5.0d2-5.0d3.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-kernel/sql/postgresql/upgrade/upgrade-5.0d2-5.0d3.sql,v diff -u -r1.7 -r1.8 --- openacs-4/packages/acs-kernel/sql/postgresql/upgrade/upgrade-5.0d2-5.0d3.sql 30 Sep 2003 12:48:00 -0000 1.7 +++ openacs-4/packages/acs-kernel/sql/postgresql/upgrade/upgrade-5.0d2-5.0d3.sql 30 Sep 2003 15:59:40 -0000 1.8 @@ -199,7 +199,12 @@ references auth_authorities(authority_id); alter table users add username varchar(100); -update users set username = (select email from parties where party_id = users.user_id); +-- set all current users' username to equal their email +-- and their authority to be the local authority +update users +set username = (select email from parties where party_id = user_id), + authority_id = (select authority_id from auth_authorities where short_name = 'local'); + -- Does not work with PG 7.2 -- alter table users alter column username set not null;