Author: fpunt Date: 2010-08-02 16:28:59 +0200 (Mon, 02 Aug 2010) New Revision: 43032
Modified: CMSContainer/trunk/CMSContainer/migration/migration_1.8.3_to_1.8.4.txt Log: [CMSC-1723] Sort sites in navigation tree Modified: CMSContainer/trunk/CMSContainer/migration/migration_1.8.3_to_1.8.4.txt =================================================================== --- CMSContainer/trunk/CMSContainer/migration/migration_1.8.3_to_1.8.4.txt 2010-08-02 14:28:37 UTC (rev 43031) +++ CMSContainer/trunk/CMSContainer/migration/migration_1.8.3_to_1.8.4.txt 2010-08-02 14:28:59 UTC (rev 43032) @@ -32,3 +32,19 @@ - compare project's overwrites near /war/src/webapp/mmbase/edit/wizard/xinha/* - take over fixes in CMSc to project! --- End script --- + + + + +Name: Hand-sortable sites +Goal: Add pos field to site builder +Type: SQL Script +--- Start script --- +ALTER TABLE mm_site ADD COLUMN pos int(11); +ALTER TABLE live_site ADD COLUMN pos int(11); + +CREATE TABLE temp_site_pos (number int(11), pos int(11)); +INSERT INTO temp_site_pos SELECT a.number, (SELECT count(*) FROM mm_site b WHERE a.number > b.number) FROM mm_site a; +UPDATE mm_site SET pos = (SELECT pos FROM temp_site_pos WHERE mm_site.number = temp_site_pos.number); +DROP TABLE temp_site_pos; +--- End script --- _______________________________________________ Cvs mailing list [email protected] http://lists.mmbase.org/mailman/listinfo/cvs
