Index: openacs-4/packages/acs-subsite/tcl/party-procs-oracle.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/tcl/Attic/party-procs-oracle.xql,v diff -u -r1.3 -r1.4 --- openacs-4/packages/acs-subsite/tcl/party-procs-oracle.xql 23 Aug 2001 21:15:56 -0000 1.3 +++ openacs-4/packages/acs-subsite/tcl/party-procs-oracle.xql 1 Sep 2001 14:54:42 -0000 1.4 @@ -3,8 +3,20 @@ oracle8.1.6 - + + (object_type = 'group' or object_type = 'person') + + + + + + object_type = :start_with + + + + + select types.pretty_name, Index: openacs-4/packages/acs-subsite/tcl/party-procs-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/tcl/Attic/party-procs-postgresql.xql,v diff -u -r1.3 -r1.4 --- openacs-4/packages/acs-subsite/tcl/party-procs-postgresql.xql 23 Aug 2001 21:15:56 -0000 1.3 +++ openacs-4/packages/acs-subsite/tcl/party-procs-postgresql.xql 1 Sep 2001 14:54:42 -0000 1.4 @@ -3,39 +3,41 @@ postgresql7.1 - + - FIX ME OUTER JOIN -FIX ME CONNECT BY -FIX ME ROWNUM + (t1.object_type = 'group' or t1.object_type = 'person') + + - select - types.pretty_name, - types.object_type, - types.tree_level, - types.indent, - case when valid_types.object_type = null then 0 else 1 end as valid_p - from - (select - t.pretty_name, t.object_type, level as tree_level, - replace(lpad(' ', (level - 1) * 4), - ' ', ' ') as indent, - rownum as tree_rownum - from - acs_object_types t - connect by - prior t.object_type = t.supertype - start with - $start_with_clause ) types, - (select - object_type - from - rel_types_valid_obj_two_types - where - rel_type = :rel_type ) valid_types - where - types.object_type = valid_types.object_type(+) - order by tree_rownum + + + t1.object_type = :start_with + + + + + + + select types.pretty_name, + types.object_type, + types.tree_level, + types.indent, + case when valid_types.object_type = null then 0 else 1 end as valid_p + from (select t2.pretty_name, + t2.object_type, + tree_level(t2.tree_sortkey) as tree_level, + repeat(' ', (tree_level(t2.tree_sortkey) - 1) * 4) as indent, + t2.tree_sortkey + from acs_object_types t1, + acs_object_types t2 + where t2.tree_sortkey like (t1.tree_sortkey || '%') + and $start_with_clause ) types + left outer join + (select object_type + from rel_types_valid_obj_two_types + where rel_type = :rel_type ) valid_types + using (object_type) + order by types.tree_sortkey Index: openacs-4/packages/acs-subsite/tcl/party-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/tcl/Attic/party-procs.tcl,v diff -u -r1.1 -r1.2 --- openacs-4/packages/acs-subsite/tcl/party-procs.tcl 13 Mar 2001 22:59:26 -0000 1.1 +++ openacs-4/packages/acs-subsite/tcl/party-procs.tcl 1 Sep 2001 14:54:42 -0000 1.2 @@ -169,9 +169,9 @@ # as an option, and we don't want to display "rel_segment" as an # option. if {[string equal $start_with "party"]} { - set start_with_clause "(object_type = 'group' or object_type = 'person')" + set start_with_clause [db_map start_with_clause_party] } else { - set start_with_clause "object_type = :start_with" + set start_with_clause [db_map start_with_clause] } db_foreach select_sub_rel_types " @@ -208,4 +208,4 @@ } -} \ No newline at end of file +}