Index: build/DatabaseStructure.sql
===================================================================
diff -u -r0a615fd8fff795947585c1a7388a7cd205b6e57e -rc020cda27aa3558aee28cce5cd2ec537ee6a9af4
--- build/DatabaseStructure.sql	(.../DatabaseStructure.sql)	(revision 0a615fd8fff795947585c1a7388a7cd205b6e57e)
+++ build/DatabaseStructure.sql	(.../DatabaseStructure.sql)	(revision c020cda27aa3558aee28cce5cd2ec537ee6a9af4)
@@ -1,6 +1,6 @@
 /* ---------------------------------------------------- */
 /*  Generated by Enterprise Architect Version 12.0 		*/
-/*  Created On : 20-Mar-2018 14:36:05 				*/
+/*  Created On : 21-Mar-2018 16:44:30 				*/
 /*  DBMS       : SQLite 								*/
 /* ---------------------------------------------------- */
 
@@ -375,16 +375,24 @@
 	'Composition' TINYINT (1) NOT NULL, -- Enum: 1 = Dike, 2 = Dune, 3 = DikeAndDune
 	'ReferenceLinePointXml' TEXT,
 	'Order' INT (4) NOT NULL,
-	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity1Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
-	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_02' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity2Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
-	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_03' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity3Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
-	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_04' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity4Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
-	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_05' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity5Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
-	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_06' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity6Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
-	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_07' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity7Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
-	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_08' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity8Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
+	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity1' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity1Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
+	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity2' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity2Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
+	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity3' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity3Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
+	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity4' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity4Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
+	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity5' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity5Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
+	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity6' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity6Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
+	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity7' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity7Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
+	CONSTRAINT 'FK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity8' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntity8Id') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE No Action ON UPDATE Cascade,
 	CONSTRAINT 'FK_AssessmentSectionEntity_ProjectEntity' FOREIGN KEY ('ProjectEntityId') REFERENCES 'ProjectEntity' ('ProjectEntityId') ON DELETE Cascade ON UPDATE Cascade,
-	CONSTRAINT 'UQ_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntities' UNIQUE ('HydraulicLocationCalculationCollectionEntity1Id','HydraulicLocationCalculationCollectionEntity2Id','HydraulicLocationCalculationCollectionEntity3Id','HydraulicLocationCalculationCollectionEntity4Id','HydraulicLocationCalculationCollectionEntity5Id','HydraulicLocationCalculationCollectionEntity6Id','HydraulicLocationCalculationCollectionEntity7Id','HydraulicLocationCalculationCollectionEntity8Id')
+	CONSTRAINT 'U_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntities' UNIQUE ('HydraulicLocationCalculationCollectionEntity1Id','HydraulicLocationCalculationCollectionEntity2Id','HydraulicLocationCalculationCollectionEntity3Id','HydraulicLocationCalculationCollectionEntity4Id','HydraulicLocationCalculationCollectionEntity5Id','HydraulicLocationCalculationCollectionEntity6Id','HydraulicLocationCalculationCollectionEntity7Id','HydraulicLocationCalculationCollectionEntity8Id'),
+	CONSTRAINT 'U_HydraulicLocationCalculationCollectionEntity1' UNIQUE ('HydraulicLocationCalculationCollectionEntity1Id'),
+	CONSTRAINT 'U_HydraulicLocationCalculationCollectionEntity2' UNIQUE ('HydraulicLocationCalculationCollectionEntity2Id'),
+	CONSTRAINT 'U_HydraulicLocationCalculationCollectionEntity3' UNIQUE ('HydraulicLocationCalculationCollectionEntity3Id'),
+	CONSTRAINT 'U_HydraulicLocationCalculationCollectionEntity4' UNIQUE ('HydraulicLocationCalculationCollectionEntity4Id'),
+	CONSTRAINT 'U_HydraulicLocationCalculationCollectionEntity5' UNIQUE ('HydraulicLocationCalculationCollectionEntity5Id'),
+	CONSTRAINT 'U_HydraulicLocationCalculationCollectionEntity6' UNIQUE ('HydraulicLocationCalculationCollectionEntity6Id'),
+	CONSTRAINT 'U_HydraulicLocationCalculationCollectionEntity7' UNIQUE ('HydraulicLocationCalculationCollectionEntity7Id'),
+	CONSTRAINT 'U_HydraulicLocationCalculationCollectionEntity8' UNIQUE ('HydraulicLocationCalculationCollectionEntity8Id')
 )
 ;
 
@@ -1943,13 +1951,14 @@
 	'HydraulicLocationCalculationCollectionEntityId' INTEGER NOT NULL,
 	CONSTRAINT 'PK_HydraulicLocationCalculationCollectionToHydraulicCalculationEntity' PRIMARY KEY ('HydraulicLocationCalculationEntityId','HydraulicLocationCalculationCollectionEntityId'),
 	CONSTRAINT 'FK_HydraulicLocationCalculationCollectionToHydraulicCalculationEntity_HydraulicLocationCalculationCollectionEntity' FOREIGN KEY ('HydraulicLocationCalculationCollectionEntityId') REFERENCES 'HydraulicLocationCalculationCollectionEntity' ('HydraulicLocationCalculationCollectionEntityId') ON DELETE Cascade ON UPDATE Cascade,
-	CONSTRAINT 'FK_HydraulicLocationCalculationCollectionToHydraulicCalculationEntity_HydraulicLocationCalculationEntity' FOREIGN KEY ('HydraulicLocationCalculationEntityId') REFERENCES 'HydraulicLocationCalculationEntity' ('HydraulicLocationCalculationEntityId') ON DELETE Cascade ON UPDATE Cascade
+	CONSTRAINT 'FK_HydraulicLocationCalculationCollectionToHydraulicCalculationEntity_HydraulicLocationCalculationEntity' FOREIGN KEY ('HydraulicLocationCalculationEntityId') REFERENCES 'HydraulicLocationCalculationEntity' ('HydraulicLocationCalculationEntityId') ON DELETE Cascade ON UPDATE Cascade,
+	CONSTRAINT 'U_HydraulicLocationCalculationEntityId' UNIQUE ('HydraulicLocationCalculationEntityId')
 )
 ;
 
 CREATE TABLE 'HydraulicLocationCalculationCollectionEntity'
 (
-	'HydraulicLocationCalculationCollectionEntityId' INTEGER NOT NULL PRIMARY KEY
+	'HydraulicLocationCalculationCollectionEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT
 )
 ;
 
@@ -1978,35 +1987,35 @@
  ON 'MacroStabilityInwardsFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
 ;
 
-CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity'
+CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity1'
  ON 'AssessmentSectionEntity' ('HydraulicLocationCalculationCollectionEntity1Id' ASC)
 ;
 
-CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_02'
+CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity2'
  ON 'AssessmentSectionEntity' ('HydraulicLocationCalculationCollectionEntity2Id' ASC)
 ;
 
-CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_03'
+CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity3'
  ON 'AssessmentSectionEntity' ('HydraulicLocationCalculationCollectionEntity3Id' ASC)
 ;
 
-CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_04'
+CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity4'
  ON 'AssessmentSectionEntity' ('HydraulicLocationCalculationCollectionEntity4Id' ASC)
 ;
 
-CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_05'
+CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity5'
  ON 'AssessmentSectionEntity' ('HydraulicLocationCalculationCollectionEntity5Id' ASC)
 ;
 
-CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_06'
+CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity6'
  ON 'AssessmentSectionEntity' ('HydraulicLocationCalculationCollectionEntity6Id' ASC)
 ;
 
-CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_07'
+CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity7'
  ON 'AssessmentSectionEntity' ('HydraulicLocationCalculationCollectionEntity7Id' ASC)
 ;
 
-CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity_08'
+CREATE INDEX 'IXFK_AssessmentSectionEntity_HydraulicLocationCalculationCollectionEntity8'
  ON 'AssessmentSectionEntity' ('HydraulicLocationCalculationCollectionEntity8Id' ASC)
 ;
 
@@ -2708,14 +2717,3 @@
 CREATE INDEX 'IXFK_HydraulicLocationCalculationCollectionToHydraulicCalculationEntity_HydraulicLocationCalculationEntity'
  ON 'HydraulicLocationCalculationCollectionToHydraulicCalculationEntity' ('HydraulicLocationCalculationEntityId' ASC)
 ;
-CREATE TRIGGER [TR_AfterDeleteHydraulicLocationCalculationCollectionEntity_RemoveHydraulicLocationCalculationEntity]
-	AFTER DELETE
-	ON HydraulicLocationCalculationCollectionEntity
-	FOR EACH ROW
-BEGIN
-	DELETE 
-	FROM HydraulicLocationCalculationEntity
-	WHERE OLD.HydraulicLocationCalculationEntityId IS NOT NULL 
-	AND HydraulicLocationCalculationEntityId IS OLD.HydraulicLocationCalculationEntityId;
-END; 
-;
