Index: openacs-4/contrib/obsolete-packages/acs-content/sql/oracle/upgrade/upgrade-4.1-4.1.1.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/contrib/obsolete-packages/acs-content/sql/oracle/upgrade/upgrade-4.1-4.1.1.sql,v diff -u --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ openacs-4/contrib/obsolete-packages/acs-content/sql/oracle/upgrade/upgrade-4.1-4.1.1.sql 28 Apr 2001 19:58:38 -0000 1.1 @@ -0,0 +1,120 @@ + +------------------------------------------------------------------------------ +-- packages/acs-content/sql/upgrade/upgrade-4.1-4.1.1.sql +-- +-- @author teeters@arsdigita.com +-- @creation-date 2000-03-06 +-- @cvs-id $Id: upgrade-4.1-4.1.1.sql,v 1.1 2001/04/28 19:58:38 donb Exp $ +-- + + +-- upgrade script. Reload package acs_content. Function new changed to procedure. +-- + + +create or replace package acs_content +as + procedure new ( + content_id in acs_contents.content_id%TYPE , + mime_type in acs_contents.mime_type%TYPE default 'text/plain', + nls_language in acs_contents.nls_language%TYPE default null, + searchable_p in acs_contents.searchable_p%TYPE default 'f', + content in acs_contents.content%TYPE default empty_blob() + ); + + procedure delete ( + content_id in acs_contents.content_id%TYPE + ); + + procedure update_nls_language ( + content_id in acs_contents.content_id%TYPE default null, + nls_language in acs_contents.nls_language%TYPE + ); + + procedure update_mime_type ( + content_id in acs_contents.content_id%TYPE default null, + mime_type in acs_contents.mime_type%TYPE + ); + + procedure update_searchable_p ( + content_id in acs_contents.content_id%TYPE default null, + searchable_p in acs_contents.searchable_p%TYPE + ); + +end acs_content; +/ + +create or replace package body acs_content +as + procedure new ( + content_id in acs_contents.content_id%TYPE, + mime_type in acs_contents.mime_type%TYPE default null, + nls_language in acs_contents.nls_language%TYPE default null, + searchable_p in acs_contents.searchable_p%TYPE default 't', + content in acs_contents.content%TYPE default empty_blob() + ) + is + v_content_id acs_contents.content_id%TYPE; + begin + insert into acs_contents ( + content_id, + mime_type, + nls_language, + searchable_p, + content + ) values ( + acs_content.new.content_id, + acs_content.new.mime_type, + acs_content.new.nls_language, + acs_content.new.searchable_p, + content + ); + end new; + + procedure delete ( + content_id in acs_contents.content_id%TYPE + ) + is + begin + delete from acs_contents + where content_id = acs_content.delete.content_id; + end delete; + + -- update language column + procedure update_nls_language ( + content_id in acs_contents.content_id%TYPE, + nls_language in acs_contents.nls_language%TYPE + ) + is + begin + update acs_contents + set nls_language = acs_content.update_nls_language.nls_language + where content_id = acs_content.update_nls_language.content_id; + end update_nls_language; + + -- update mime type column + procedure update_mime_type ( + content_id in acs_contents.content_id%TYPE, + mime_type in acs_contents.mime_type%TYPE + ) + is + begin + update acs_contents + set mime_type = acs_content.update_mime_type.mime_type + where content_id = acs_content.update_mime_type.content_id; + end update_mime_type; + + -- update searchable p column + procedure update_searchable_p ( + content_id in acs_contents.content_id%TYPE, + searchable_p in acs_contents.searchable_p%TYPE + ) + is + begin + update acs_contents + set searchable_p = acs_content.update_searchable_p.searchable_p + where content_id = acs_content.update_searchable_p.content_id; + end update_searchable_p; +end acs_content; +/ + Index: openacs-4/contrib/obsolete-packages/acs-content/sql/postgresql/acs-content-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/contrib/obsolete-packages/acs-content/sql/postgresql/acs-content-create.sql,v diff -u -r1.1 -r1.2 --- openacs-4/contrib/obsolete-packages/acs-content/sql/postgresql/acs-content-create.sql 3 Apr 2001 05:18:30 -0000 1.1 +++ openacs-4/contrib/obsolete-packages/acs-content/sql/postgresql/acs-content-create.sql 28 Apr 2001 19:58:38 -0000 1.2 @@ -19,7 +19,7 @@ searchable_p boolean default 't' constraint acs_cont_searchable_p_ck check (searchable_p in ('t','f')), -- stores the language of the content - nls_language varchar(50) default '' not null, + nls_language varchar(50), -- mime type mime_type varchar(200) default 'text/plain' ); Index: openacs-4/contrib/obsolete-packages/acs-workflow/sql/postgresql/wf-core-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/contrib/obsolete-packages/acs-workflow/sql/postgresql/wf-core-create.sql,v diff -u -r1.3 -r1.4 --- openacs-4/contrib/obsolete-packages/acs-workflow/sql/postgresql/wf-core-create.sql 13 Apr 2001 04:31:27 -0000 1.3 +++ openacs-4/contrib/obsolete-packages/acs-workflow/sql/postgresql/wf-core-create.sql 28 Apr 2001 19:58:39 -0000 1.4 @@ -50,15 +50,15 @@ constraint wf_workflows_workflow_key_fk references acs_object_types(object_type) on delete cascade, - description text default '' not null + description text ); comment on table wf_workflows is ' Parent table for the workflow definition. '; create table wf_places ( - place_key varchar(100) default '' not null, + place_key varchar(100), workflow_key varchar(100) constraint wf_place_workflow_fk references wf_workflows(workflow_key) @@ -82,7 +82,7 @@ '; create table wf_transitions ( - transition_key varchar(100) default '' not null, + transition_key varchar(100), transition_name varchar(100) constraint wf_transition_name_nn not null, @@ -94,7 +94,7 @@ sort_order integer constraint wf_transition_order_ck check (sort_order > 0), - trigger_type varchar(40) default '' not null + trigger_type varchar(40) constraint wf_transition_trigger_type_ck check (trigger_type in ('','automatic','user','message','time')), @@ -113,10 +113,10 @@ constraint wf_ts_arc_workflow_fk references wf_workflows(workflow_key) on delete cascade, - transition_key varchar(100) default '' not null, - place_key varchar(100) default '' not null, + transition_key varchar(100), + place_key varchar(100), -- direction is relative to the transition - direction varchar(3) default '' not null + direction varchar(3) constraint wf_arc_direction_ck check (direction in ('','in','out')), /* Must be satisfied for the arc to be traveled by a token @@ -125,9 +125,9 @@ * place_key in varchar, direction in varchar2, custom_arg in varchar2) * return char(1) */ - guard_callback varchar(100) default '' not null, - guard_custom_arg text default '' not null, - guard_description varchar(500) default '' not null, + guard_callback varchar(100), + guard_custom_arg text, + guard_description varchar(500), constraint wf_arc_guard_on_in_arc_ck check (guard_callback = '' or direction = 'out'), constraint wf_arc_transition_fk @@ -158,7 +158,7 @@ constraint wf_attribute_info_attribute_fk references acs_attributes(attribute_id) on delete cascade, - wf_datatype varchar(50) default '' not null + wf_datatype varchar(50) constraint wf_attr_info_wf_datatype_ck check (wf_datatype in ('', 'none', 'party')) ); @@ -169,7 +169,7 @@ constraint wf_trans_attr_map_workflow_fk references wf_workflows(workflow_key) on delete cascade, - transition_key varchar(100) default '' not null, + transition_key varchar(100), -- so the user can decide in what order the attributes should be presented sort_order integer not null, attribute_id integer @@ -193,8 +193,8 @@ constraint wf_trans_asgn_map_workflow_fk references wf_workflows(workflow_key) on delete cascade, - transition_key varchar(100) default '' not null, - assign_transition_key varchar(100) default '' not null, + transition_key varchar(100), + assign_transition_key varchar(100), constraint wf_trans_asgn_map_pk primary key (workflow_key, transition_key, assign_transition_key), constraint wf_trans_asgn_map_trans_fk @@ -266,48 +266,48 @@ workflow_key varchar(100) constraint wf_context_trans_workflow_fk references wf_workflows, - transition_key varchar(100) default '' not null, + transition_key varchar(100), /* information for the transition in the context */ /* The integer of minutes this task is estimated to take */ estimated_minutes integer, /* * Will be called when the transition is enabled/fired. * signature: (case_id in integer, transition_key in varchar, custom_arg in varchar2) */ - enable_callback varchar(100) default '' not null, - enable_custom_arg text default '' not null, - fire_callback varchar(100) default '' not null, - fire_custom_arg text default '' not null, + enable_callback varchar(100), + enable_custom_arg text, + fire_callback varchar(100), + fire_custom_arg text, /* * Must insert rows into the wf_task_assignments table. * Will be called when the transition becomes enabled * signature: (task_id in integer, custom_arg in varchar) */ - assignment_callback varchar(100) default '' not null, - assignment_custom_arg text default '' not null, + assignment_callback varchar(100), + assignment_custom_arg text, /* * Must return the date that the timed transition should fire * Will be called when the transition is enabled * signature: (case_id in integer, transition_key in varchar, custom_arg in varchar2) return date */ - time_callback varchar(100) default '' not null, - time_custom_arg text default '' not null, + time_callback varchar(100), + time_custom_arg text, /* * Returns the deadline for this task. * Will be called when the transition becomes enabled * Signature: (case_id in integer, transition_key in varchar, custom_arg in varchar2) return date */ - deadline_callback varchar(100) default '' not null, - deadline_custom_arg text default '' not null, + deadline_callback varchar(100), + deadline_custom_arg text, /* The name of an attribute that holds the deadline */ - deadline_attribute_name varchar(100) default '' not null, + deadline_attribute_name varchar(100), /* * Must return the date that the user's hold on the task times out. * called when the user starts the task. * signature: (case_id in integer, transition_key in varchar, custom_arg in varchar2) return date */ - hold_timeout_callback varchar(100) default '' not null, - hold_timeout_custom_arg text default '' not null, + hold_timeout_callback varchar(100), + hold_timeout_custom_arg text, /* * Notification callback * Will be called when a notification is sent i.e., when a transition is enabled, @@ -319,19 +319,19 @@ * subject in out varchar, * body in out varchar) */ - notification_callback varchar(100) default '' not null, - notification_custom_arg text default '' not null, + notification_callback varchar(100), + notification_custom_arg text, /* * Unassigned callback * Will be called whenever a task becomes unassigned * Signature: (case_id in integer, transition_key in varchar, custom_arg in varchar2) */ - unassigned_callback varchar(100) default '' not null, - unassigned_custom_arg text default '' not null, + unassigned_callback varchar(100), + unassigned_custom_arg text, /* name of the privilege we should check before allowing access * to task information. */ - access_privilege text default '' not null, + access_privilege text, /* table constraints */ constraint wf_context_trans_trans_fk foreign key (workflow_key, transition_key) references wf_transitions(workflow_key, transition_key) @@ -386,7 +386,7 @@ constraint wf_context_assign_workflow_fk references wf_workflows(workflow_key) on delete cascade, - transition_key varchar(100) default '' not null, + transition_key varchar(100), party_id integer constraint wf_context_assign_party_fk references parties(party_id) @@ -464,8 +464,8 @@ constraint wf_case_assign_fk references wf_cases(case_id) on delete cascade, - workflow_key varchar(100) default '' not null, - transition_key varchar(100) default '' not null, + workflow_key varchar(100), + transition_key varchar(100), party_id integer constraint wf_case_assign_party_fk references parties(party_id) @@ -488,8 +488,8 @@ constraint wf_case_deadline_fk references wf_cases(case_id) on delete cascade, - workflow_key varchar(100) default '' not null, - transition_key varchar(100) default '' not null, + workflow_key varchar(100), + transition_key varchar(100), deadline timestamp constraint wf_case_deadline_nn not null, @@ -521,7 +521,7 @@ workflow_key varchar(100) constraint wf_task_workflow_fk references wf_workflows(workflow_key), - transition_key varchar(100) default '' not null, + transition_key varchar(100), /* Information about the task */ state varchar(40) default 'enabled' @@ -588,7 +588,7 @@ constraint wf_token_workflow_fk references wf_workflows(workflow_key), -- a token must always be in some place - place_key varchar(100) default '' not null, + place_key varchar(100), state varchar(40) default 'free' constraint wf_tokens_state_ck check (state in ('free', 'locked', 'canceled', 'consumed')), @@ -640,7 +640,7 @@ journal_id integer constraint wf_attr_val_audit_journal_fk references journal_entries(journal_id), - attr_value text default '' not null, + attr_value text, constraint wf_attr_val_audit_pk primary key (case_id, attribute_id, journal_id) ); Fisheye: Tag 1.2 refers to a dead (removed) revision in file `openacs-4/contrib/obsolete-packages/acs-workflow/sql/test/workflow-case-package-test.sql'. Fisheye: No comparison available. Pass `N' to diff? Fisheye: Tag 1.2 refers to a dead (removed) revision in file `openacs-4/packages/acs-admin/www/index.xql'. Fisheye: No comparison available. Pass `N' to diff? Index: openacs-4/packages/acs-admin/www/users/index.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/users/index.xql,v diff -u -r1.1 -r1.2 --- openacs-4/packages/acs-admin/www/users/index.xql 27 Apr 2001 01:41:12 -0000 1.1 +++ openacs-4/packages/acs-admin/www/users/index.xql 28 Apr 2001 19:58:38 -0000 1.2 @@ -3,9 +3,8 @@ - FIX ME DECODE (USE SQL92 CASE) select - count(*) as n_users, - sum(decode(member_state,'deleted',1,0)) as n_deleted_users, + select count(*) as n_users, + sum(case when member_state = 'deleted' then 1 else 0 end) as n_deleted_users, max(creation_date) as last_registration from cc_users where email not in ('anonymous', 'system') Index: openacs-4/packages/acs-admin/www/users/member-state-change-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/users/Attic/member-state-change-postgresql.xql,v diff -u -r1.1 -r1.2 --- openacs-4/packages/acs-admin/www/users/member-state-change-postgresql.xql 27 Apr 2001 01:41:12 -0000 1.1 +++ openacs-4/packages/acs-admin/www/users/member-state-change-postgresql.xql 28 Apr 2001 19:58:38 -0000 1.2 @@ -5,9 +5,11 @@ - select email_verified_p email_verified_p_old, member_state member_state_old, first_names || ' ' || last_name as name, email, rel_id, rowid -from cc_users -where user_id = :user_id + select email_verified_p as email_verified_p_old, + member_state as member_state_old, + first_names || ' ' || last_name as name, email, rel_id, oid + from cc_users + where user_id = :user_id Index: openacs-4/packages/acs-admin/www/users/one.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/users/one.xql,v diff -u -r1.1 -r1.2 --- openacs-4/packages/acs-admin/www/users/one.xql 27 Apr 2001 01:41:12 -0000 1.1 +++ openacs-4/packages/acs-admin/www/users/one.xql 28 Apr 2001 19:58:38 -0000 1.2 @@ -3,32 +3,36 @@ - select first_names, last_name, email, coalesce(screen_name,'< none set up >') as screen_name, creation_date, creation_ip, last_visit, member_state, email_verified_p -from cc_users -where user_id = :user_id + select first_names, last_name, email, + coalesce(screen_name,'< none set up >') as screen_name, + creation_date, creation_ip, last_visit, member_state, email_verified_p + from cc_users + where user_id = :user_id - select live_revision as revision_id, coalesce(title,'view this portrait') portrait_title -from acs_rels a, cr_items c, cr_revisions cr -where a.object_id_two = c.item_id -and c.live_revision = cr.revision_id -and a.object_id_one = :user_id -and a.rel_type = 'user_portrait_rel' + select live_revision as revision_id, + coalesce(title,'view this portrait') as portrait_title + from acs_rels a, cr_items c, cr_revisions cr + where a.object_id_two = c.item_id + and c.live_revision = cr.revision_id + and a.object_id_one = :user_id + and a.rel_type = 'user_portrait_rel' - select at.pretty_name, at.pretty_plural, a.creation_date, acs_object.name(a.object_id) object_name -from acs_objects a, acs_object_types at -where a.object_type = at.object_type -and a.creation_user = :user_id -order by object_name, creation_date + select at.pretty_name, at.pretty_plural, a.creation_date, + acs_object.name(a.object_id) as object_name + from acs_objects a, acs_object_types at + where a.object_type = at.object_type + and a.creation_user = :user_id + order by object_name, creation_date Index: openacs-4/packages/acs-content-repository/sql/postgresql/content-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/sql/postgresql/content-create.sql,v diff -u -r1.11 -r1.12 --- openacs-4/packages/acs-content-repository/sql/postgresql/content-create.sql 17 Apr 2001 04:10:06 -0000 1.11 +++ openacs-4/packages/acs-content-repository/sql/postgresql/content-create.sql 28 Apr 2001 19:58:38 -0000 1.12 @@ -43,11 +43,11 @@ -------------------------------------------------------------- create table cr_mime_types ( - label varchar(200) default '' not null, + label varchar(200), mime_type varchar(200) constraint cr_mime_types_pk primary key, - file_extension varchar(200) default '' not null + file_extension varchar(200) ); @@ -100,8 +100,8 @@ nls_language varchar(30) constraint cr_locale_nls_lang_nil not null, - nls_territory varchar(30) default '' not null, - nls_charset varchar(30) default '' not null + nls_territory varchar(30), + nls_charset varchar(30) ); comment on table cr_locales is ' @@ -321,7 +321,7 @@ child_id integer constraint cr_child_rels_child_nil not null, - relation_tag varchar(100) default '' not null, + relation_tag varchar(100), order_n integer ); @@ -346,7 +346,7 @@ related_object_id integer constraint cr_item_rels_rel_obj__fk references acs_objects, - relation_tag varchar(100) default '' not null, + relation_tag varchar(100), order_n integer ); @@ -385,13 +385,13 @@ not null constraint cr_revisions_item_id_fk references cr_items on delete cascade, - title varchar(1000) default '' not null, - description text default '' not null, + title varchar(1000), + description text, publish_date timestamp, mime_type varchar(200) default 'text/plain' constraint cr_revisions_mime_type_ref references cr_mime_types, - nls_language varchar(50) default '' not null, + nls_language varchar(50), -- use Don's postgresql lob hack for now. storage_type varchar(10) default 'lob' not null constraint cr_revisions_storage_type @@ -400,7 +400,7 @@ lob integer, -- content holds the file name if storage type = file -- otherwise it holds the text data if storage_type = text. - content text default '' not null, + content text, content_length integer ); @@ -435,7 +435,7 @@ primary key constraint cr_revision_attributes_fk references cr_revisions, - attributes text default '' not null + attributes text ); comment on column cr_revision_attributes.attributes is ' @@ -473,8 +473,8 @@ new_revision integer constraint cr_item_pub_audit_new_rev_fk references cr_revisions, - old_status varchar(40) default '' not null, - new_status varchar(40) default '' not null, + old_status varchar(40), + new_status varchar(40), publish_date timestamp constraint cr_item_publish_audit_date_nil not null @@ -502,7 +502,7 @@ items_released integer not null, items_expired integer not null, err_num integer, - err_msg varchar(500) default '' not null + err_msg varchar(500) ); comment on table cr_scheduled_release_log is ' @@ -531,8 +531,8 @@ cr_items on delete cascade constraint cr_folders_pk primary key, - label varchar(1000) default '' not null, - description text default '' not null, + label varchar(1000), + description text, has_child_folders boolean default 'f', has_child_symlinks boolean default 'f' ); @@ -674,7 +674,7 @@ references cr_items constraint cr_symlink_target_id_nil not null, - label varchar(1000) default '' not null + label varchar(1000) ); create index cr_symlinks_by_target_id on cr_symlinks(target_id); @@ -699,7 +699,7 @@ label varchar(1000) constraint cr_extlink_label_nil not null, - description text default '' not null + description text ); comment on table cr_extlinks is ' @@ -721,7 +721,7 @@ heading varchar(600) constraint cr_keywords_name_nil not null, - description text default '' not null, + description text, has_children boolean, tree_sortkey varchar(4000) ); Index: openacs-4/packages/acs-content-repository/sql/postgresql/content-extlink.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/sql/postgresql/content-extlink.sql,v diff -u -r1.5 -r1.6 --- openacs-4/packages/acs-content-repository/sql/postgresql/content-extlink.sql 18 Apr 2001 23:27:46 -0000 1.5 +++ openacs-4/packages/acs-content-repository/sql/postgresql/content-extlink.sql 28 Apr 2001 19:58:39 -0000 1.6 @@ -64,7 +64,7 @@ insert into cr_extlinks (extlink_id, url, label, description) values - (v_extlink_id, new__url, v_label, coalesce(new__description,'''')); + (v_extlink_id, new__url, v_label, new__description); return v_extlink_id; Index: openacs-4/packages/acs-content-repository/sql/postgresql/content-folder.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/sql/postgresql/content-folder.sql,v diff -u -r1.12 -r1.13 --- openacs-4/packages/acs-content-repository/sql/postgresql/content-folder.sql 19 Apr 2001 01:17:17 -0000 1.12 +++ openacs-4/packages/acs-content-repository/sql/postgresql/content-folder.sql 28 Apr 2001 19:58:39 -0000 1.13 @@ -87,7 +87,7 @@ insert into cr_folders ( folder_id, label, description ) values ( - v_folder_id, coalesce(new__label,''''), coalesce(new__description,'''') + v_folder_id, new__label, new__description ); -- inherit the attributes of the parent folder Index: openacs-4/packages/acs-content-repository/sql/postgresql/content-item.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/sql/postgresql/content-item.sql,v diff -u -r1.13 -r1.14 --- openacs-4/packages/acs-content-repository/sql/postgresql/content-item.sql 19 Apr 2001 01:17:17 -0000 1.13 +++ openacs-4/packages/acs-content-repository/sql/postgresql/content-item.sql 28 Apr 2001 19:58:39 -0000 1.14 @@ -193,7 +193,7 @@ insert into cr_child_rels ( rel_id, parent_id, child_id, relation_tag, order_n ) values ( - v_rel_id, v_parent_id, v_item_id, coalesce(v_rel_tag,''''), v_item_id + v_rel_id, v_parent_id, v_item_id, v_rel_tag, v_item_id ); end if; @@ -1746,7 +1746,7 @@ rel_id, item_id, related_object_id, order_n, relation_tag ) values ( v_rel_id, relate__item_id, relate__object_id, v_order_n, - coalesce(relate__relation_tag,'''') + relate__relation_tag ); -- if relationship already exists, update it @@ -1860,7 +1860,7 @@ item_id, old_revision, new_revision, old_status, new_status, publish_date ) values ( new.item_id, old.live_revision, new.live_revision, - coalesce(old.publish_status,''''), coalesce(new.publish_status,''''), + old.publish_status, new.publish_status, now() ); Index: openacs-4/packages/acs-content-repository/sql/postgresql/content-keyword.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/sql/postgresql/content-keyword.sql,v diff -u -r1.6 -r1.7 --- openacs-4/packages/acs-content-repository/sql/postgresql/content-keyword.sql 18 Apr 2001 23:27:46 -0000 1.6 +++ openacs-4/packages/acs-content-repository/sql/postgresql/content-keyword.sql 28 Apr 2001 19:58:39 -0000 1.7 @@ -118,7 +118,7 @@ insert into cr_keywords (heading, description, keyword_id, parent_id) values - (new__heading, coalesce(new__description,''''), v_id, new__parent_id); + (new__heading, new__description, v_id, new__parent_id); return v_id; Index: openacs-4/packages/acs-content-repository/sql/postgresql/content-revision.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/sql/postgresql/content-revision.sql,v diff -u -r1.12 -r1.13 --- openacs-4/packages/acs-content-repository/sql/postgresql/content-revision.sql 27 Apr 2001 02:27:09 -0000 1.12 +++ openacs-4/packages/acs-content-repository/sql/postgresql/content-revision.sql 28 Apr 2001 19:58:39 -0000 1.13 @@ -51,9 +51,9 @@ revision_id, title, description, mime_type, publish_date, nls_language, lob, item_id, storage_type, content_length ) values ( - v_revision_id, coalesce(new__title,''''), coalesce(new__description,''''), + v_revision_id, new__title, new__description, new__mime_type, - new__publish_date, coalesce(new__nls_language,''''), new__data, + new__publish_date, new__nls_language, new__data, new__item_id, ''lob'', 1 ); @@ -121,10 +121,10 @@ revision_id, title, description, mime_type, publish_date, nls_language, content, item_id, storage_type, content_length ) values ( - v_revision_id, coalesce(new__title,''''), coalesce(new__description,''''), + v_revision_id, new__title, new__description, new__mime_type, - new__publish_date, coalesce(new__nls_language,''''), - coalesce(new__text,''''), new__item_id, ''text'', + new__publish_date, new__nls_language, + new__text, new__item_id, ''text'', length(new__text) ); Index: openacs-4/packages/acs-content-repository/sql/postgresql/content-schedule.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/sql/postgresql/content-schedule.sql,v diff -u -r1.4 -r1.5 --- openacs-4/packages/acs-content-repository/sql/postgresql/content-schedule.sql 2 Apr 2001 05:35:29 -0000 1.4 +++ openacs-4/packages/acs-content-repository/sql/postgresql/content-schedule.sql 28 Apr 2001 19:58:39 -0000 1.5 @@ -92,7 +92,7 @@ items_released, items_expired, err_num, err_msg ) values ( exec__items_released, exec__items_expired, exec__err_num, - coalesce(exec__err_msg,'''') + exec__err_msg ); -- Reset the last time of execution to start of processing Index: openacs-4/packages/acs-content-repository/sql/postgresql/content-symlink.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/sql/postgresql/content-symlink.sql,v diff -u -r1.7 -r1.8 --- openacs-4/packages/acs-content-repository/sql/postgresql/content-symlink.sql 19 Apr 2001 01:17:17 -0000 1.7 +++ openacs-4/packages/acs-content-repository/sql/postgresql/content-symlink.sql 28 Apr 2001 19:58:39 -0000 1.8 @@ -100,7 +100,7 @@ insert into cr_symlinks (symlink_id, target_id, label) values - (v_symlink_id, new__target_id, coalesce(v_label,'''')); + (v_symlink_id, new__target_id, v_label); return v_symlink_id; Index: openacs-4/packages/acs-content-repository/sql/postgresql/content-type.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/sql/postgresql/content-type.sql,v diff -u -r1.13 -r1.14 --- openacs-4/packages/acs-content-repository/sql/postgresql/content-type.sql 18 Apr 2001 23:27:46 -0000 1.13 +++ openacs-4/packages/acs-content-repository/sql/postgresql/content-type.sql 28 Apr 2001 19:58:39 -0000 1.14 @@ -687,7 +687,7 @@ parent_type, child_type, relation_tag, min_n, max_n ) values ( register_child_type__parent_type, register_child_type__child_type, - coalesce(register_child_type__relation_tag,''''), + register_child_type__relation_tag, register_child_type__min_n, register_child_type__max_n ); @@ -763,7 +763,7 @@ ) values ( register_relation_type__content_type, register_relation_type__target_type, - coalesce(register_relation_type__relation_tag,''''), + register_relation_type__relation_tag, register_relation_type__min_n, register_relation_type__max_n ); Index: openacs-4/packages/acs-content-repository/sql/postgresql/content-xml.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-content-repository/sql/postgresql/content-xml.sql,v diff -u -r1.2 -r1.3 --- openacs-4/packages/acs-content-repository/sql/postgresql/content-xml.sql 29 Mar 2001 02:46:30 -0000 1.2 +++ openacs-4/packages/acs-content-repository/sql/postgresql/content-xml.sql 28 Apr 2001 19:58:39 -0000 1.3 @@ -22,7 +22,7 @@ create table cr_xml_docs ( doc_id integer primary key, - doc text default '' not null + doc text ); comment on table cr_xml_docs is ' Index: openacs-4/packages/acs-tcl/tcl/utilities-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/utilities-procs.tcl,v diff -u -r1.2 -r1.3 --- openacs-4/packages/acs-tcl/tcl/utilities-procs.tcl 12 Apr 2001 16:58:18 -0000 1.2 +++ openacs-4/packages/acs-tcl/tcl/utilities-procs.tcl 28 Apr 2001 19:58:39 -0000 1.3 @@ -411,6 +411,7 @@ } proc_doc util_AnsiDatetoPrettyDate {sql_date} "Converts 1998-09-05 to September 5, 1998" { + set sql_date [string range $sql_date 0 9] if ![regexp {(.*)-(.*)-(.*)$} $sql_date match year month day] { return "" } else {