From 7ac41a06f73b8efffded217a23201bb7e0964e8e Mon Sep 17 00:00:00 2001 From: Fred Gleason Date: Tue, 19 Feb 2019 15:06:31 -0500 Subject: [PATCH] 2019-02-19 Fred Gleason * Dropped the 'RDLIBRARY.INSTANCE' field from the database. * Incremented the database version to 306. --- ChangeLog | 3 +++ lib/dbversion.h | 2 +- utils/rddbmgr/revertschema.cpp | 17 +++++++++++++++++ utils/rddbmgr/schemamap.cpp | 4 ++-- utils/rddbmgr/updateschema.cpp | 10 ++++++++++ 5 files changed, 33 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 615e893d..867a413b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -18487,3 +18487,6 @@ 2019-02-19 Fred Gleason * Changed the minimum size of the 'Edit PyPAD Instance dialog in rdadmin(1) to be 600x660. +2019-02-19 Fred Gleason + * Dropped the 'RDLIBRARY.INSTANCE' field from the database. + * Incremented the database version to 306. diff --git a/lib/dbversion.h b/lib/dbversion.h index 68ebe13e..861e24af 100644 --- a/lib/dbversion.h +++ b/lib/dbversion.h @@ -24,7 +24,7 @@ /* * Current Database Version */ -#define RD_VERSION_DATABASE 305 +#define RD_VERSION_DATABASE 306 #endif // DBVERSION_H diff --git a/utils/rddbmgr/revertschema.cpp b/utils/rddbmgr/revertschema.cpp index bead0c07..124dd2c3 100644 --- a/utils/rddbmgr/revertschema.cpp +++ b/utils/rddbmgr/revertschema.cpp @@ -40,6 +40,23 @@ bool MainObject::RevertSchema(int cur_schema,int set_schema,QString *err_msg) // NEW SCHEMA REVERSIONS GO HERE... + // + // Revert 306 + // + if((cur_schema==306)&&(set_schemacur_schema)) { + sql=QString("alter table RDLIBRARY drop index STATION_IDX"); + RDSqlQuery::apply(sql); + DropColumn("RDLIBRARY","INSTANCE"); + sql=QString("create index STATION_IDX on RDLIBRARY (STATION)"); + RDSqlQuery::apply(sql); + + WriteSchemaVersion(++cur_schema); + } + // NEW SCHEMA UPDATES GO HERE...