Shakir-Sopra / NMDSdevopsServiceAdm-NMDSDB-SFC

0 stars 1 forks source link

Replaying the DDL #4

Open wozzer72 opened 5 years ago

wozzer72 commented 5 years ago

Having created a new database instance at home, I have tried to replay the DDL but with the following changes:

  1. Corrections to the insert SQL for ServicesCapacity - was using double quotes should be single.
  2. Added inserts for services 2.1. Which also required removing the auto increment on id colunn (see issue 3). 2.2. Should remove the unnecessary columns
  3. Commented out the default tablespaces. - we need to agree if tablespaces are in fact necessary (especially with cloud storage abstraction).
  4. Adding "if not exists" to the create schema.
  5. Adding "if not exists" to all create table.
  6. Deleted "log_id_seq" as it is never used
  7. Swapped the order of columns on ServicesCapacity for those times when issuing select * from.
wozzer72 commented 5 years ago

cqc-schema-ddl-create-and-drop.zip

wozzer72 commented 5 years ago

Revised create DDL to accommodate the rename on the EstablishmentLocalAuthority.EstablishmentLocalAuthorityID, which because I consolidated, it impacted on order/sequence of creates & alters. cqc-schema-ddl-create-and-drop.zip

wozzer72 commented 5 years ago

Corrected the unique constraint on EstablishmentCapacity table. cqc-schema-ddl-create-and-drop.zip