Index: openacs-4/packages/dotlrn/sql/oracle/upgrade/upgrade-july-25-2002.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/oracle/upgrade/upgrade-july-25-2002.sql,v diff -u --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ openacs-4/packages/dotlrn/sql/oracle/upgrade/upgrade-july-25-2002.sql 26 Jul 2002 01:57:54 -0000 1.1 @@ -0,0 +1 @@ +alter table dotlrn_terms modify term_year varchar2(9); Index: openacs-4/packages/dotlrn/sql/postgresql/classes-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/classes-create.sql,v diff -u -r1.2 -r1.3 --- openacs-4/packages/dotlrn/sql/postgresql/classes-create.sql 11 Jul 2002 15:54:13 -0000 1.2 +++ openacs-4/packages/dotlrn/sql/postgresql/classes-create.sql 26 Jul 2002 01:57:35 -0000 1.3 @@ -59,7 +59,7 @@ term_name varchar(20) constraint dotlrn_t_term_name_nn not null, - term_year varchar(4) + term_year varchar(9) constraint dotlrn_t_term_year_nn not null, start_date date Index: openacs-4/packages/dotlrn/sql/postgresql/upgrade/upgrade-july-25-2002.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/sql/postgresql/upgrade/upgrade-july-25-2002.sql,v diff -u --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ openacs-4/packages/dotlrn/sql/postgresql/upgrade/upgrade-july-25-2002.sql 26 Jul 2002 01:57:35 -0000 1.1 @@ -0,0 +1,27 @@ + +drop index dotlrn_terms_pk; + +create table new_dotlrn_terms ( + term_id integer + constraint dotlrn_terms_pk + primary key, + term_name varchar(20) + constraint dotlrn_t_term_name_nn + not null, + term_year varchar(9) + constraint dotlrn_t_term_year_nn + not null, + start_date date + default now() + constraint dotlrn_t_start_date_nn + not null, + end_date date + default (now() + '180 days'::timespan) + constraint dotlrn_t_end_date_nn + not null +); + +insert into new_dotlrn_terms select * from dotlrn_terms; +alter table dotlrn_terms rename to old_dotlrn_terms; +alter table new_dotlrn_terms rename to dotlrn_terms; +drop table old_dotlrn_terms;