Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-admins-init.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-admins-init.sql,v diff -u -r1.4 -r1.5 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-admins-init.sql 3 Jul 2002 19:58:07 -0000 1.4 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-admins-init.sql 8 Jul 2002 04:12:21 -0000 1.5 @@ -26,7 +26,7 @@ returns integer as ' declare foo integer; - group_id integer; + gid integer; dotlrn_users_group_id integer; begin @@ -53,7 +53,7 @@ from acs_sc_impls where impl_name = ''dotlrn_admin_profile_provider''; - group_id := profiled_group__new( + gid := profiled_group__new( foo, ''dotLRN Admins'' ); @@ -62,11 +62,11 @@ into dotlrn_user_types (type, pretty_name, group_id) values - (''admin'', ''Staff'', group_id); + (''admin'', ''Staff'', gid); foo := rel_segment__new( ''dotLRN Admins'', - group_id, + gid, ''dotlrn_admin_profile_rel'' ); @@ -77,9 +77,11 @@ foo := composition_rel__new( dotlrn_users_group_id, - group_id + gid ); + return 0; + end; ' language 'plpgsql'; Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-externals-init.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-externals-init.sql,v diff -u -r1.4 -r1.5 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-externals-init.sql 3 Jul 2002 19:58:07 -0000 1.4 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-externals-init.sql 8 Jul 2002 04:12:21 -0000 1.5 @@ -26,7 +26,7 @@ returns integer as ' declare foo integer; - group_id integer; + gid integer; dotlrn_users_group_id integer; begin @@ -53,7 +53,7 @@ from acs_sc_impls where impl_name = ''dotlrn_external_profile_provider''; - group_id := profiled_group__new( + gid := profiled_group__new( foo, ''dotLRN Externals'' ); @@ -62,11 +62,11 @@ into dotlrn_user_types (type, pretty_name, group_id) values - (''external'', ''dotLRN Externals'', group_id); + (''external'', ''dotLRN Externals'', gid); foo := rel_segment__new( ''dotLRN Externals'', - group_id, + gid, ''dotlrn_external_profile_rel'' ); @@ -77,9 +77,11 @@ foo := composition_rel__new( dotlrn_users_group_id, - group_id + gid ); + return 0; + end; ' language 'plpgsql'; Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-professors-init.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-professors-init.sql,v diff -u -r1.5 -r1.6 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-professors-init.sql 3 Jul 2002 19:58:07 -0000 1.5 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-professors-init.sql 8 Jul 2002 04:12:21 -0000 1.6 @@ -26,7 +26,7 @@ returns integer as ' declare foo integer; - group_id integer; + gid integer; dotlrn_users_group_id integer; begin @@ -53,7 +53,7 @@ from acs_sc_impls where impl_name = ''dotlrn_professor_profile_provider''; - group_id := profiled_group__new( + gid := profiled_group__new( foo, ''dotLRN Professors'' ); @@ -62,11 +62,11 @@ into dotlrn_user_types (type, pretty_name, group_id) values - (''professor'', ''Professor'', group_id); + (''professor'', ''Professor'', gid); foo := rel_segment__new( ''dotLRN Professors'', - group_id, + gid, ''dotlrn_professor_profile_rel'' ); @@ -77,7 +77,7 @@ foo := composition_rel__new( dotlrn_users_group_id, - group_id + gid ); return 0; Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-students-init.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-students-init.sql,v diff -u -r1.5 -r1.6 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-students-init.sql 3 Jul 2002 19:58:07 -0000 1.5 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-students-init.sql 8 Jul 2002 04:12:21 -0000 1.6 @@ -26,7 +26,7 @@ returns integer as ' declare foo integer; - group_id integer; + gid integer; dotlrn_users_group_id integer; begin @@ -53,7 +53,7 @@ from acs_sc_impls where impl_name = ''dotlrn_student_profile_provider''; - group_id := profiled_group__new( + gid := profiled_group__new( foo, ''dotLRN Students'' ); @@ -62,11 +62,11 @@ into dotlrn_user_types (type, pretty_name, group_id) values - (''student'', ''Student'', group_id); + (''student'', ''Student'', gid); foo := rel_segment__new( ''dotLRN Students'', - group_id, + gid, ''dotlrn_student_profile_rel'' ); @@ -77,7 +77,7 @@ foo := composition_rel__new( dotlrn_users_group_id, - group_id + gid ); return 0; Index: openacs-4/packages/dotlrn/sql/postgresql/dotlrn-users-init.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/Attic/dotlrn-users-init.sql,v diff -u -r1.4 -r1.5 --- openacs-4/packages/dotlrn/sql/postgresql/dotlrn-users-init.sql 2 Jul 2002 19:53:51 -0000 1.4 +++ openacs-4/packages/dotlrn/sql/postgresql/dotlrn-users-init.sql 8 Jul 2002 04:12:21 -0000 1.5 @@ -29,8 +29,8 @@ perform acs_rel_type__create_type( ''dotlrn_user_profile_rel'', - ''dotLRN User Profile Membership'', - ''dotLRN User Profile Memberships'', + ''dotLRN Profile User'', + ''dotLRN Profile Users'', ''user_profile_rel'', ''dotlrn_user_profile_rels'', ''rel_id'', @@ -56,7 +56,7 @@ ); foo := rel_segment__new( - ''dotLRN Profiled Users'', + ''dotLRN Users'', foo, ''dotlrn_user_profile_rel'' ); @@ -67,47 +67,3 @@ select inline_1(); drop function inline_1(); - -create function inline_2() -returns integer as ' -declare - foo integer; -begin - PERFORM acs_rel_type__create_type( - ''dotlrn_full_user_profile_rel'', - ''dotLRN Full User Profile Membership'', - ''dotLRN Full User Profile Memberships'', - ''dotlrn_user_profile_rel'', - ''dotlrn_full_user_profile_rels'', - ''rel_id'', - ''dotlrn_full_user_profile_rel'', - ''profiled_group'', - null, - 0, - null, - ''user'', - null, - 0, - 1 - ); - - select min(group_id) - into foo - from profiled_groups - where profile_provider = (select min(impl_id) - from acs_sc_impls - where impl_name = ''dotlrn_user_profile_provider''); - - foo := rel_segment__new( - ''dotLRN Full Profiled Users'', - foo, - ''dotlrn_full_user_profile_rel'' - ); - - return (0); -end; -' language 'plpgsql'; - -select inline_2(); -drop function inline_2(); -