dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #24116
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 11772: Changed field type for datavalue.lastupdated (timestamp) from date to timestamp.
------------------------------------------------------------
revno: 11772
committer: Lars Helge Øverland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2013-08-23 14:47:51 +0200
message:
Changed field type for datavalue.lastupdated (timestamp) from date to timestamp.
modified:
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java
dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/datavalue/hibernate/DataValue.hbm.xml
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java 2013-08-22 17:09:11 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/startup/TableAlteror.java 2013-08-23 12:47:51 +0000
@@ -160,8 +160,6 @@
executeSql( "ALTER TABLE mapview RENAME COLUMN maplegendsetid TO legendsetid" );
executeSql( "ALTER TABLE mapview ALTER COLUMN opacity TYPE double precision" );
- //TODO executeSql( "ALTER TABLE datavalue ALTER COLUMN storedby TYPE character varying(100)" );
-
executeSql( "ALTER TABLE maplegend DROP CONSTRAINT maplegend_name_key" );
executeSql( "UPDATE mapview SET layer = 'thematic1' WHERE layer IS NULL" );
@@ -628,6 +626,8 @@
executeSql( "UPDATE dashboard SET publicaccess='--------' WHERE publicaccess is null" );
executeSql( "UPDATE optionset SET version=1 WHERE version IS NULL" );
+
+ executeSql( "ALTER TABLE datavalue ALTER COLUMN lastupdated TYPE timestamp" );
log.info( "Tables updated" );
}
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/datavalue/hibernate/DataValue.hbm.xml'
--- dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/datavalue/hibernate/DataValue.hbm.xml 2013-06-26 12:31:29 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/datavalue/hibernate/DataValue.hbm.xml 2013-08-23 12:47:51 +0000
@@ -17,7 +17,7 @@
<property name="storedBy" column="storedby" length="100" />
- <property name="timestamp" column="lastupdated" type="date" />
+ <property name="timestamp" column="lastupdated" type="timestamp" />
<property name="comment" length="360" />