head	1.4;
access;
symbols
	TIGRIS_1_1_0RC2:1.4
	TIGRIS_1_1_0RC1:1.4
	TIGRIS_1_1:1.4.0.4
	TIGRIS_1_0_8:1.4
	TIGRIS_1_0_8RC3:1.4
	TIGRIS_1_0_8RC2:1.4
	TIGRIS_1_0_8RC1:1.4
	TIGRIS_1_0_7:1.4
	TIGRIS_1_0_7RC3:1.4
	TIGRIS_1_0_7RC2:1.4
	TIGRIS_1_0_7RC1:1.4
	TIGRIS_1_0_6:1.4
	TIGRIS_1_0_6RC5:1.4
	TIGRIS_1_0_6RC4:1.4
	TIGRIS_1_0_6RC3:1.4
	TIGRIS_1_0_6RC2:1.4
	TIGRIS_1_0_6RC1:1.4
	TIGRIS_1_0_5:1.4
	TIGRIS_1_0_5RC6:1.4
	TIGRIS_1_0_5RC5:1.4
	TIGRIS_1_0_5RC4:1.4
	TIGRIS_1_0_5RC3:1.4
	TIGRIS_1_0_5RC2:1.4
	TIGRIS_1_0_5RC1:1.4
	TIGRIS_1_0_4:1.4
	TIGRIS_1_0_3:1.4
	TIGRIS_1_0_2:1.4
	TIGRIS_1_0_1:1.4
	TIGRIS_1_0:1.4.0.6
	TIGRIS_1_0_0:1.4
	TIGRIS_1_0_0_RC1:1.4.0.2;
locks; strict;
comment	@# @;


1.4
date	2001.03.25.22.39.09;	author leonardr;	state Exp;
branches;
next	1.3;

1.3
date	2001.03.25.22.14.43;	author jrobbins;	state Exp;
branches;
next	1.2;

1.2
date	2001.03.25.21.48.41;	author jrobbins;	state Exp;
branches;
next	1.1;

1.1
date	2001.03.24.03.16.37;	author leonardr;	state Exp;
branches;
next	;


desc
@@


1.4
log
@Got rid of SQL problems.
@
text
@#New roles.
drop table if exists xxxx_populate_UserRoleProject;
create table xxxx_populate_UserRoleProject
(
        USER_LOGIN    varchar(32) NOT NULL,
        ROLE_NAME     varchar(99) NOT NULL,
        PROJECT_NAME  varchar(64) NOT NULL,
        APPROVED_BY   varchar(32)
);

insert into xxxx_populate_UserRoleProject (USER_LOGIN, ROLE_NAME, PROJECT_NAME, APPROVED_BY)
       values 
              ("guest", "Anonymous Guest",          "*All public projects in domain", "root")
            , ("guest", "Click-through Viewer",          "*All projects in domain", "root")
;

insert into HELM_USER_ROLE_PROJECT (USER_ID, ROLE_ID, PROJECT_ID, APPROVED_BY)
       select distinct User.userID, Role.roleID, Project.PROJECT_ID, Approved.userID
         from xxxx_populate_UserRoleProject as Tmp,
              User as User,
              Role as Role,
              HELM_PROJECT as Project,
              User as Approved
        where Tmp.USER_LOGIN   = User.loginID
          and Tmp.ROLE_NAME    = Role.name
          and Tmp.PROJECT_NAME = Project.NAME
          and Tmp.APPROVED_BY  = Approved.loginID
;

drop table if exists xxxx_populate_UserRoleProject;

@


1.3
log
@corrected table names
@
text
@d18 1
a18 1
       select distinct User.userID, Role.roleID, Project.PROJECT_ID, Approved.USER_ID
d24 1
a24 1
        where Tmp.USER_LOGIN   = User.loginName
d27 1
a27 1
          and Tmp.APPROVED_BY  = Approved.loginName
@


1.2
log
@table and column name fixes
@
text
@d18 1
a18 1
       select distinct User.USER_ID, Role.ROLE_ID, Project.PROJECT_ID, Approved.USER_ID
@


1.1
log
@First stab at 0.9.0->0.9.2 migration scripts.
@
text
@d20 2
a21 2
              HELM_USER as User,
              HELM_ROLE as Role,
d23 3
a25 3
              HELM_USER as Approved
        where Tmp.USER_LOGIN   = User.LOGIN_NAME
          and Tmp.ROLE_NAME    = Role.NAME
d27 1
a27 1
          and Tmp.APPROVED_BY  = Approved.LOGIN_NAME
@

