You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@roller.apache.org by ag...@apache.org on 2005/09/19 23:43:42 UTC

svn commit: r290279 - in /incubator/roller/branches/roller_2.0/metadata/database: 120-to-200-migration-raw.sql createdb-raw.sql

Author: agilliland
Date: Mon Sep 19 14:43:39 2005
New Revision: 290279

URL: http://svn.apache.org/viewcvs?rev=290279&view=rev
Log:
modified weblogentry.pubtime field type from "timestamp" to "datetime".

migration script now has an alter table statement to modify the existing column for upgrades.


Modified:
    incubator/roller/branches/roller_2.0/metadata/database/120-to-200-migration-raw.sql
    incubator/roller/branches/roller_2.0/metadata/database/createdb-raw.sql

Modified: incubator/roller/branches/roller_2.0/metadata/database/120-to-200-migration-raw.sql
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/metadata/database/120-to-200-migration-raw.sql?rev=290279&r1=290278&r2=290279&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/metadata/database/120-to-200-migration-raw.sql (original)
+++ incubator/roller/branches/roller_2.0/metadata/database/120-to-200-migration-raw.sql Mon Sep 19 14:43:39 2005
@@ -29,11 +29,6 @@
 
 -- -----------------------------------------------------
 
-insert roller_properties (name,value) values ('site.shortName','');
-insert roller_properties (name,value) values ('planet.cache.dir','/var/roller/planet-cache');
-
--- -----------------------------------------------------
-
 -- Audit log records time and comment about change
 -- user_id: user that made change
 -- object_id: id of associated object, if any
@@ -49,6 +44,16 @@
     change_time     timestamp              
 );
 
+
+-- -----------------------------------------------------
+
+-- update weblogentry.pubtime to be a "datetime" field instead of "timestamp"
+-- "timestamp" doesn't work anymore because we want the value to be null until
+-- the weblogentry is published, and "timestamps" are set automatically
+
+alter table weblogentry modify pubtime datetime NULL;
+
+
 -- -----------------------------------------------------
 -- For ROL-754. MySQL 5.x introduced a new keyword "condition"
 -- which made the use of "condition" as a column name in the "pingtarget" table illegal.
@@ -246,4 +251,4 @@
     foreign key (autopingid) references autoping(id) @ADDL_FK_PARAMS@ ;
 
 alter table pingcategory add constraint pc_categoryid_fk
-    foreign key (categoryid) references weblogcategory(id) @ADDL_FK_PARAMS@ 
\ No newline at end of file
+    foreign key (categoryid) references weblogcategory(id) @ADDL_FK_PARAMS@ 

Modified: incubator/roller/branches/roller_2.0/metadata/database/createdb-raw.sql
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller_2.0/metadata/database/createdb-raw.sql?rev=290279&r1=290278&r2=290279&view=diff
==============================================================================
--- incubator/roller/branches/roller_2.0/metadata/database/createdb-raw.sql (original)
+++ incubator/roller/branches/roller_2.0/metadata/database/createdb-raw.sql Mon Sep 19 14:43:39 2005
@@ -173,7 +173,7 @@
     anchor          varchar(255)  not null,
     title           varchar(255)  not null,
     text            @TEXT_SQL_TYPE@ not null,
-    pubtime         timestamp     not null,
+    pubtime         datetime     not null,
     updatetime      timestamp     not null,
     websiteid       varchar(48)  not null,
     categoryid      varchar(48)  not null,