Index: Application/Ringtoets/src/Application.Ringtoets.Migration.Core/EmbeddedResources/DatabaseStructure17.2.sql
===================================================================
diff -u -r43403466c934b16bad9ec2960c884b6fad9c9a18 -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Migration.Core/EmbeddedResources/DatabaseStructure17.2.sql (.../DatabaseStructure17.2.sql) (revision 43403466c934b16bad9ec2960c884b6fad9c9a18)
+++ Application/Ringtoets/src/Application.Ringtoets.Migration.Core/EmbeddedResources/DatabaseStructure17.2.sql (.../DatabaseStructure17.2.sql) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -1,15 +1,15 @@
/* ---------------------------------------------------- */
/* Generated by Enterprise Architect Version 12.0 */
-/* Created On : 05-Jul-2017 11:39:12 */
+/* Created On : 13-Jul-2017 2:06:57 PM */
/* DBMS : SQLite */
/* ---------------------------------------------------- */
/* Drop Tables */
-DROP TABLE IF EXISTS 'VersionEntity'
+DROP TABLE IF EXISTS 'GrassCoverErosionInwardsDikeHeightOutputEntity'
;
-DROP TABLE IF EXISTS 'GrassCoverErosionInwardsDikeHeightOutputEntity'
+DROP TABLE IF EXISTS 'VersionEntity'
;
DROP TABLE IF EXISTS 'ProjectEntity'
@@ -36,24 +36,24 @@
DROP TABLE IF EXISTS 'ClosingStructuresFailureMechanismMetaEntity'
;
-DROP TABLE IF EXISTS 'CalculationGroupEntity'
-;
-
DROP TABLE IF EXISTS 'StabilityPointStructuresFailureMechanismMetaEntity'
;
-DROP TABLE IF EXISTS 'DuneErosionFailureMechanismMetaEntity'
+DROP TABLE IF EXISTS 'CalculationGroupEntity'
;
DROP TABLE IF EXISTS 'HydraulicLocationEntity'
;
-DROP TABLE IF EXISTS 'PipingCalculationEntity'
+DROP TABLE IF EXISTS 'DuneErosionFailureMechanismMetaEntity'
;
DROP TABLE IF EXISTS 'GrassCoverErosionInwardsFailureMechanismMetaEntity'
;
+DROP TABLE IF EXISTS 'PipingCalculationEntity'
+;
+
DROP TABLE IF EXISTS 'HeightStructuresFailureMechanismMetaEntity'
;
@@ -234,23 +234,32 @@
DROP TABLE IF EXISTS 'GeneralResultSubMechanismIllustrationPointStochastEntity'
;
+DROP TABLE IF EXISTS 'GeneralResultFaultTreeIllustrationPointEntity'
+;
+
+DROP TABLE IF EXISTS 'FaultTreeIllustrationPointEntity'
+;
+
+DROP TABLE IF EXISTS 'FaultTreeIllustrationPointStochastEntity'
+;
+
+DROP TABLE IF EXISTS 'GeneralResultFaultTreeIllustrationPointStochastEntity'
+;
+
DROP TABLE IF EXISTS 'TopLevelSubMechanismIllustrationPointEntity'
;
+DROP TABLE IF EXISTS 'TopLevelFaultTreeIllustrationPointEntity'
+;
+
DROP TABLE IF EXISTS 'SubMechanismIllustrationPointStochastEntity'
;
-/* Create Tables with Primary and Foreign Keys, Check and Unique Constraints */
-
-CREATE TABLE 'VersionEntity'
-(
- 'VersionId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- 'Version' VARCHAR (20) NOT NULL,
- 'Timestamp' DATETIME NOT NULL,
- 'FingerPrint' BLOB NOT NULL
-)
+DROP TABLE IF EXISTS 'FaultTreeSubmechanismIllustrationPointEntity'
;
+/* Create Tables with Primary and Foreign Keys, Check and Unique Constraints */
+
CREATE TABLE 'GrassCoverErosionInwardsDikeHeightOutputEntity'
(
'GrassCoverErosionInwardsDikeHeightOutputEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -266,6 +275,15 @@
)
;
+CREATE TABLE 'VersionEntity'
+(
+ 'VersionId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'Version' VARCHAR (20) NOT NULL,
+ 'Timestamp' DATETIME NOT NULL,
+ 'FingerPrint' BLOB NOT NULL
+)
+;
+
CREATE TABLE 'ProjectEntity'
(
'ProjectEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -420,16 +438,6 @@
)
;
-CREATE TABLE 'CalculationGroupEntity'
-(
- 'CalculationGroupEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- 'ParentCalculationGroupEntityId' INTEGER,
- 'Name' VARCHAR (260),
- 'Order' INT (4) NOT NULL,
- CONSTRAINT 'FK_CalculationGroupEntity_CalculationGroupEntity' FOREIGN KEY ('ParentCalculationGroupEntityId') REFERENCES 'CalculationGroupEntity' ('CalculationGroupEntityId') ON DELETE Cascade ON UPDATE Cascade
-)
-;
-
CREATE TABLE 'StabilityPointStructuresFailureMechanismMetaEntity'
(
'StabilityPointStructuresFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -441,12 +449,13 @@
)
;
-CREATE TABLE 'DuneErosionFailureMechanismMetaEntity'
+CREATE TABLE 'CalculationGroupEntity'
(
- 'DuneErosionFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- 'FailureMechanismEntityId' INTEGER NOT NULL,
- 'N' REAL NOT NULL,
- CONSTRAINT 'FK_DuneErosionFailureMechanismMetaEntity_FailureMechanismEntity' FOREIGN KEY ('FailureMechanismEntityId') REFERENCES 'FailureMechanismEntity' ('FailureMechanismEntityId') ON DELETE Cascade ON UPDATE Cascade
+ 'CalculationGroupEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'ParentCalculationGroupEntityId' INTEGER,
+ 'Name' VARCHAR (260),
+ 'Order' INT (4) NOT NULL,
+ CONSTRAINT 'FK_CalculationGroupEntity_CalculationGroupEntity' FOREIGN KEY ('ParentCalculationGroupEntityId') REFERENCES 'CalculationGroupEntity' ('CalculationGroupEntityId') ON DELETE Cascade ON UPDATE Cascade
)
;
@@ -465,6 +474,25 @@
)
;
+CREATE TABLE 'DuneErosionFailureMechanismMetaEntity'
+(
+ 'DuneErosionFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'FailureMechanismEntityId' INTEGER NOT NULL,
+ 'N' REAL NOT NULL,
+ CONSTRAINT 'FK_DuneErosionFailureMechanismMetaEntity_FailureMechanismEntity' FOREIGN KEY ('FailureMechanismEntityId') REFERENCES 'FailureMechanismEntity' ('FailureMechanismEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
+CREATE TABLE 'GrassCoverErosionInwardsFailureMechanismMetaEntity'
+(
+ 'GrassCoverErosionInwardsFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'FailureMechanismEntityId' INTEGER NOT NULL,
+ 'N' INT (4) NOT NULL,
+ 'DikeProfileCollectionSourcePath' TEXT,
+ CONSTRAINT 'FK_GrassCoverErosionInwardsFailureMechanismMetaEntity_FailureMechanismEntity' FOREIGN KEY ('FailureMechanismEntityId') REFERENCES 'FailureMechanismEntity' ('FailureMechanismEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
CREATE TABLE 'PipingCalculationEntity'
(
'PipingCalculationEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -492,16 +520,6 @@
)
;
-CREATE TABLE 'GrassCoverErosionInwardsFailureMechanismMetaEntity'
-(
- 'GrassCoverErosionInwardsFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- 'FailureMechanismEntityId' INTEGER NOT NULL,
- 'N' INT (4) NOT NULL,
- 'DikeProfileCollectionSourcePath' TEXT,
- CONSTRAINT 'FK_GrassCoverErosionInwardsFailureMechanismMetaEntity_FailureMechanismEntity' FOREIGN KEY ('FailureMechanismEntityId') REFERENCES 'FailureMechanismEntity' ('FailureMechanismEntityId') ON DELETE Cascade ON UPDATE Cascade
-)
-;
-
CREATE TABLE 'HeightStructuresFailureMechanismMetaEntity'
(
'HeightStructuresFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -1088,11 +1106,13 @@
(
'HeightStructuresOutputEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
'HeightStructuresCalculationEntityId' INTEGER NOT NULL,
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER,
'RequiredProbability' REAL,
'RequiredReliability' REAL,
'Probability' REAL,
'Reliability' REAL,
'FactorOfSafety' REAL,
+ CONSTRAINT 'FK_HeightStructuresOutputEntity_GeneralResultFaultTreeIllustrationPointEntity' FOREIGN KEY ('GeneralResultFaultTreeIllustrationPointEntityId') REFERENCES 'GeneralResultFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId') ON DELETE Set Null ON UPDATE Cascade,
CONSTRAINT 'FK_HeightStructuresOutputEntity_HeightStructuresCalculationEntity' FOREIGN KEY ('HeightStructuresCalculationEntityId') REFERENCES 'HeightStructuresCalculationEntity' ('HeightStructuresCalculationEntityId') ON DELETE Cascade ON UPDATE Cascade,
CONSTRAINT 'U_HeightStructuresCalculationEntity' UNIQUE ('HeightStructuresCalculationEntityId')
)
@@ -1258,12 +1278,14 @@
(
'ClosingStructuresOutputEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
'ClosingStructuresCalculationEntityId' INTEGER NOT NULL,
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER,
'RequiredProbability' REAL,
'RequiredReliability' REAL,
'Probability' REAL,
'Reliability' REAL,
'FactorOfSafety' REAL,
CONSTRAINT 'FK_ClosingStructuresOutputEntity_ClosingStructuresCalculationEntity' FOREIGN KEY ('ClosingStructuresCalculationEntityId') REFERENCES 'ClosingStructuresCalculationEntity' ('ClosingStructuresCalculationEntityId') ON DELETE Cascade ON UPDATE Cascade,
+ CONSTRAINT 'FK_ClosingStructuresOutputEntity_GeneralResultFaultTreeIllustrationPointEntity' FOREIGN KEY ('GeneralResultFaultTreeIllustrationPointEntityId') REFERENCES 'GeneralResultFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId') ON DELETE Set Null ON UPDATE Cascade,
CONSTRAINT 'U_ClosingStructuresCalculationEntity' UNIQUE ('ClosingStructuresCalculationEntityId')
)
;
@@ -1330,11 +1352,13 @@
(
'StabilityPointStructuresOutputEntity' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
'StabilityPointStructuresCalculationEntityId' INTEGER NOT NULL,
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER,
'RequiredProbability' REAL,
'RequiredReliability' REAL,
'Probability' REAL,
'Reliability' REAL,
'FactorOfSafety' REAL,
+ CONSTRAINT 'FK_StabilityPointStructuresOutputEntity_GeneralResultFaultTreeIllustrationPointEntity' FOREIGN KEY ('GeneralResultFaultTreeIllustrationPointEntityId') REFERENCES 'GeneralResultFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId') ON DELETE Set Null ON UPDATE Cascade,
CONSTRAINT 'FK_StabilityPointStructuresOutputEntity_StabilityPointStructuresCalculationEntity' FOREIGN KEY ('StabilityPointStructuresCalculationEntityId') REFERENCES 'StabilityPointStructuresCalculationEntity' ('StabilityPointStructuresCalculationEntityId') ON DELETE Cascade ON UPDATE Cascade,
CONSTRAINT 'U_StabilityPointStructuresCalculationEntity' UNIQUE ('StabilityPointStructuresCalculationEntityId')
)
@@ -1352,7 +1376,7 @@
'CalculatedProbability' REAL,
'CalculatedReliability' REAL,
'CalculationConvergence' TINYINT (1) NOT NULL, -- Enum: 1 = NotCalculated, 2 = CalculatedNotConverged, 3 = CalculatedConverged
- CONSTRAINT 'FK_HydraulicLocationOutputEntity_GeneralResultSubMechanismIllustrationPointEntity' FOREIGN KEY ('GeneralResultSubMechanismIllustrationPointEntityId') REFERENCES 'GeneralResultSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId') ON DELETE No Action ON UPDATE No Action,
+ CONSTRAINT 'FK_HydraulicLocationOutputEntity_GeneralResultSubMechanismIllustrationPointEntity' FOREIGN KEY ('GeneralResultSubMechanismIllustrationPointEntityId') REFERENCES 'GeneralResultSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId') ON DELETE Set Null ON UPDATE Cascade,
CONSTRAINT 'FK_HydraulicLocationOutputEntity_HydraulicLocationEntity' FOREIGN KEY ('HydraulicLocationEntityId') REFERENCES 'HydraulicLocationEntity' ('HydraulicLocationEntityId') ON DELETE Cascade ON UPDATE Cascade,
CONSTRAINT 'U_HydraulicLocationEntityOutputType' UNIQUE ('HydraulicLocationEntityId','HydraulicLocationOutputType')
)
@@ -1370,7 +1394,7 @@
'CalculatedProbability' REAL,
'CalculatedReliability' REAL,
'CalculationConvergence' TINYINT (1) NOT NULL, -- Enum: 1 = NotCalculated, 2 = CalculatedNotConverged, 3 = CalculatedConverged
- CONSTRAINT 'FK_GrassCoverErosionOutwardsHydraulicLocationOutputEntity_GeneralResultSubMechanismIllustrationPointEntity' FOREIGN KEY ('GeneralResultSubMechanismIllustrationPointEntityId') REFERENCES 'GeneralResultSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId') ON DELETE No Action ON UPDATE No Action,
+ CONSTRAINT 'FK_GrassCoverErosionOutwardsHydraulicLocationOutputEntity_GeneralResultSubMechanismIllustrationPointEntity' FOREIGN KEY ('GeneralResultSubMechanismIllustrationPointEntityId') REFERENCES 'GeneralResultSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId') ON DELETE Set Null ON UPDATE Cascade,
CONSTRAINT 'FK_GrassCoverErosionOutwardsHydraulicLocationOutputEntity_GrassCoverErosionOutwardsHydraulicLocationEntity' FOREIGN KEY ('GrassCoverErosionOutwardsHydraulicLocationEntityId') REFERENCES 'GrassCoverErosionOutwardsHydraulicLocationEntity' ('GrassCoverErosionOutwardsHydraulicLocationEntityId') ON DELETE Cascade ON UPDATE Cascade,
CONSTRAINT 'U_HydraulicLocationOutputType' UNIQUE ('GrassCoverErosionOutwardsHydraulicLocationEntityId','HydraulicLocationOutputType')
)
@@ -1491,10 +1515,50 @@
'StochastEntityId' INTEGER NOT NULL,
CONSTRAINT 'PK_GeneralResultSubMechanismIllustrationPointStochastEntity' PRIMARY KEY ('GeneralResultSubMechanismIllustrationPointEntityId','StochastEntityId'),
CONSTRAINT 'FK_GeneralResultSubMechanisIllustrationPointStochastEntity_GeneralResultSubMechanismIllustrationPointEntity' FOREIGN KEY ('GeneralResultSubMechanismIllustrationPointEntityId') REFERENCES 'GeneralResultSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade,
- CONSTRAINT 'FK_GeneralResultSubMechanismIllustrationPointStochastEntity_StochastEntity' FOREIGN KEY ('StochastEntityId') REFERENCES 'StochastEntity' ('StochastEntityId') ON DELETE No Action ON UPDATE No Action
+ CONSTRAINT 'FK_GeneralResultSubMechanismIllustrationPointStochastEntity_StochastEntity' FOREIGN KEY ('StochastEntityId') REFERENCES 'StochastEntity' ('StochastEntityId') ON DELETE Cascade ON UPDATE Cascade
)
;
+CREATE TABLE 'GeneralResultFaultTreeIllustrationPointEntity'
+(
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'GoverningWindDirectionName' TEXT NOT NULL,
+ 'GoverningWindDirectionAngle' REAL NOT NULL
+)
+;
+
+CREATE TABLE 'FaultTreeIllustrationPointEntity'
+(
+ 'FaultTreeIllustrationPointEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'ParentFaultTreeIllustrationPointEntityId' INTEGER,
+ 'Name' TEXT NOT NULL,
+ 'Beta' REAL NOT NULL,
+ 'CombinationType' TINYINT (1) NOT NULL, -- Enum: 1 = Or, 2 = And
+ 'Order' INT (4) NOT NULL,
+ CONSTRAINT 'FK_FaultTreeIllustrationPoint_FaultTreeIllustrationPoint' FOREIGN KEY ('ParentFaultTreeIllustrationPointEntityId') REFERENCES 'FaultTreeIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
+CREATE TABLE 'FaultTreeIllustrationPointStochastEntity'
+(
+ 'FaultTreeIllustrationPointEntityId' INTEGER NOT NULL,
+ 'StochastEntityId' INTEGER NOT NULL,
+ CONSTRAINT 'PK_FaultTreeIllustrationPointStochastEntity' PRIMARY KEY ('FaultTreeIllustrationPointEntityId','StochastEntityId'),
+ CONSTRAINT 'FK_FaultTreeIllustrationPointStochastEntity_FaultTreeIllustrationPoint' FOREIGN KEY ('FaultTreeIllustrationPointEntityId') REFERENCES 'FaultTreeIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId') ON DELETE No Action ON UPDATE No Action,
+ CONSTRAINT 'FK_FaultTreeIllustrationPointStochastEntity_StochastEntity' FOREIGN KEY ('StochastEntityId') REFERENCES 'StochastEntity' ('StochastEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
+CREATE TABLE 'GeneralResultFaultTreeIllustrationPointStochastEntity'
+(
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER NOT NULL,
+ 'StochastEntityId' INTEGER NOT NULL,
+ CONSTRAINT 'PK_GeneralResultFaultTreeIllustrationPointStochastEntity' PRIMARY KEY ('GeneralResultFaultTreeIllustrationPointEntityId','StochastEntityId'),
+ CONSTRAINT 'FK_GeneralResultFaultTreeIllustrationPointStochastEntity_GeneralResultFaultTreeIllustrationPointEntity' FOREIGN KEY ('GeneralResultFaultTreeIllustrationPointEntityId') REFERENCES 'GeneralResultFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade,
+ CONSTRAINT 'FK_GeneralResultFaultTreeIllustrationPointStochastEntity_StochastEntity' FOREIGN KEY ('StochastEntityId') REFERENCES 'StochastEntity' ('StochastEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
CREATE TABLE 'TopLevelSubMechanismIllustrationPointEntity'
(
'TopLevelSubMechanismIllustrationPointEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -1509,6 +1573,20 @@
)
;
+CREATE TABLE 'TopLevelFaultTreeIllustrationPointEntity'
+(
+ 'TopLevelFaultTreeIllustrationPointEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'FaultTreeIllustrationPointEntityId' INTEGER NOT NULL,
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER NOT NULL,
+ 'ClosingSituation' TEXT NOT NULL,
+ 'WindDirectionName' TEXT NOT NULL,
+ 'WindDirectionAngle' REAL NOT NULL,
+ 'Order' INT (4) NOT NULL,
+ CONSTRAINT 'FK_TopLevelFaultTreeIllustrationPointEntity_FaultTreeIllustrationPointEntity' FOREIGN KEY ('FaultTreeIllustrationPointEntityId') REFERENCES 'FaultTreeIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade,
+ CONSTRAINT 'FK_TopLevelFaultTreeIllustrationPointEntity_GeneralResultFaultTreeIllustrationPointEntity' FOREIGN KEY ('GeneralResultFaultTreeIllustrationPointEntityId') REFERENCES 'GeneralResultFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
CREATE TABLE 'SubMechanismIllustrationPointStochastEntity'
(
'SubMechanismIllustrationPointStochastEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -1522,6 +1600,16 @@
)
;
+CREATE TABLE 'FaultTreeSubmechanismIllustrationPointEntity'
+(
+ 'SubMechanismIllustrationPointEntityId' INTEGER NOT NULL,
+ 'FaultTreeIllustrationPointEntityId' INTEGER NOT NULL,
+ CONSTRAINT 'PK_FaultTreeSubMechanismIllustrationPointEntityId' PRIMARY KEY ('SubMechanismIllustrationPointEntityId','FaultTreeIllustrationPointEntityId'),
+ CONSTRAINT 'FK_FaultTreeIllustrationPointEntity_FaultTreeIllustrationPointEntity' FOREIGN KEY ('FaultTreeIllustrationPointEntityId') REFERENCES 'FaultTreeIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade,
+ CONSTRAINT 'FK_FaultTreeIllustrationPointEntity_SubMechanismIllustrationPointEntity' FOREIGN KEY ('SubMechanismIllustrationPointEntityId') REFERENCES 'SubMechanismIllustrationPointEntity' ('SubMechanismIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
/* Create Indexes and Triggers */
CREATE INDEX 'IXFK_GrassCoverErosionInwardsDikeHeightOutputEntity_GrassCoverErosionInwardsOutputEntity'
@@ -1572,20 +1660,24 @@
ON 'ClosingStructuresFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
;
+CREATE INDEX 'IXFK_StrengthStabilityPointConstructionFailureMechanismMetaEntity_FailureMechanismEntity'
+ ON 'StabilityPointStructuresFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
+;
+
CREATE INDEX 'IXFK_CalculationGroupEntity_CalculationGroupEntity'
ON 'CalculationGroupEntity' ('ParentCalculationGroupEntityId' ASC)
;
-CREATE INDEX 'IXFK_StrengthStabilityPointConstructionFailureMechanismMetaEntity_FailureMechanismEntity'
- ON 'StabilityPointStructuresFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
+CREATE INDEX 'IXFK_HydraulicLocationEntity_AssessmentSectionEntity'
+ ON 'HydraulicLocationEntity' ('AssessmentSectionEntityId' ASC)
;
CREATE INDEX 'IXFK_DuneErosionFailureMechanismMetaEntity_FailureMechanismEntity'
ON 'DuneErosionFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
;
-CREATE INDEX 'IXFK_HydraulicLocationEntity_AssessmentSectionEntity'
- ON 'HydraulicLocationEntity' ('AssessmentSectionEntityId' ASC)
+CREATE INDEX 'IXFK_GrassCoverErosionInwardsFailureMechanismMetaEntity_FailureMechanismEntity'
+ ON 'GrassCoverErosionInwardsFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
;
CREATE INDEX 'IXFK_PipingCalculationEntity_StochasticSoilProfileEntity'
@@ -1604,10 +1696,6 @@
ON 'PipingCalculationEntity' ('CalculationGroupEntityId' ASC)
;
-CREATE INDEX 'IXFK_GrassCoverErosionInwardsFailureMechanismMetaEntity_FailureMechanismEntity'
- ON 'GrassCoverErosionInwardsFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
-;
-
CREATE INDEX 'IXFK_HeightStructuresFailureMechanismMetaEntity_FailureMechanismEntity'
ON 'HeightStructuresFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
;
@@ -1946,6 +2034,48 @@
END;
;
+CREATE INDEX 'IXFK_FaultTreeIllustrationPoint_FaultTreeIllustrationPoint'
+ ON 'FaultTreeIllustrationPointEntity' ('ParentFaultTreeIllustrationPointEntityId' ASC)
+;
+
+CREATE INDEX 'IXFK_FaultTreeIllustrationPointStochastEntity_FaultTreeIllustrationPoint'
+ ON 'FaultTreeIllustrationPointStochastEntity' ('FaultTreeIllustrationPointEntityId' ASC)
+;
+
+CREATE INDEX 'IXFK_FaultTreeIllustrationPointStochastEntity_StochastEntity'
+ ON 'FaultTreeIllustrationPointStochastEntity' ('StochastEntityId' ASC)
+;
+CREATE TRIGGER [TR_AfterDeleteFaultTreeIllustrationPointStochastEntity_RemoveStochastEntity]
+ AFTER DELETE
+ ON FaultTreeIllustrationPointStochastEntity
+ FOR EACH ROW
+BEGIN
+ DELETE
+ FROM StochastEntity
+ WHERE OLD.StochastEntityId IS NOT NULL
+ AND StochastEntityId IS OLD.StochastEntityId;
+END;
+;
+
+CREATE INDEX 'IXFK_GeneralResultFaultTreeIllustrationPointStochastEntity_GeneralResultFaultTreeIllustrationPointEntity'
+ ON 'GeneralResultFaultTreeIllustrationPointStochastEntity' ('GeneralResultFaultTreeIllustrationPointEntityId' ASC)
+;
+
+CREATE INDEX 'IXFK_GeneralResultFaultTreeIllustrationPointStochastEntity_StochastEntity'
+ ON 'GeneralResultFaultTreeIllustrationPointStochastEntity' ('StochastEntityId' ASC)
+;
+CREATE TRIGGER [TR_AfterDeleteGeneralResultFaultTreeIllustrationPointStochastEntity_RemoveStochastEntity]
+ AFTER DELETE
+ ON GeneralResultFaultTreeIllustrationPointStochastEntity
+ FOR EACH ROW
+BEGIN
+ DELETE
+ FROM StochastEntity
+ WHERE OLD.StochastEntityId IS NOT NULL
+ AND StochastEntityId IS OLD.StochastEntityId;
+END;
+;
+
CREATE INDEX 'IXFK_TopLevelSubMechanismIllustrationPointEntity_GeneralResultSubMechanismIllustrationPointEntity'
ON 'TopLevelSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId' ASC)
;
@@ -1964,6 +2094,42 @@
END;
;
+CREATE INDEX 'IXFK_TopLevelFaultTreeIllustrationPointEntity_FaultTreeIllustrationPointEntity'
+ ON 'TopLevelFaultTreeIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId' ASC)
+;
+
+CREATE INDEX 'IXFK_TopLevelFaultTreeIllustrationPointEntity_GeneralResultFaultTreeIllustrationPointEntity'
+ ON 'TopLevelFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId' ASC)
+;
+CREATE TRIGGER [TR_AfterDeleteTopLevelFaultTreeIllustrationPointEntity_RemoveFaultTreeIllustrationPointEntity]
+ AFTER DELETE
+ ON TopLevelFaultTreeIllustrationPointEntity
+ FOR EACH ROW
+BEGIN
+ DELETE FROM FaultTreeIllustrationPointEntity
+ WHERE OLD.FaultTreeIllustrationPointEntityId IS NOT NULL AND
+ FaultTreeIllustrationPointEntityId IS OLD.FaultTreeIllustrationPointEntityId;
+END;
+;
+
CREATE INDEX 'IXFK_SubMechanismIllustrationPointStochast_SubMechanismIllustrationPointEntity'
ON 'SubMechanismIllustrationPointStochastEntity' ('SubMechanismIllustrationPointEntityId' ASC)
;
+
+CREATE INDEX 'IXFK_FaultTreeIllustrationPointEntity_FaultTreeIllustrationPointEntity'
+ ON 'FaultTreeSubmechanismIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId' ASC)
+;
+
+CREATE INDEX 'IXFK_FaultTreeIllustrationPointEntity_SubMechanismIllustrationPointEntity'
+ ON 'FaultTreeSubmechanismIllustrationPointEntity' ('SubMechanismIllustrationPointEntityId' ASC)
+;
+CREATE TRIGGER [TR_AfterDeleteFaultTreeSubmechanismIllustrationPointEntity_RemoveSubmechanismIllustrationPointEntity]
+ AFTER DELETE
+ ON FaultTreeSubmechanismIllustrationPointEntity
+ FOR EACH ROW
+BEGIN
+ DELETE FROM SubmechanismIllustrationPointEntity
+ WHERE OLD.SubmechanismIllustrationPointEntityId IS NOT NULL AND
+ SubmechanismIllustrationPointEntityId IS OLD.SubmechanismIllustrationPointEntityId;
+END;
+;
Index: Application/Ringtoets/src/Application.Ringtoets.Migration.Core/EmbeddedResources/Migration_17.1_17.2.sql
===================================================================
diff -u -r43403466c934b16bad9ec2960c884b6fad9c9a18 -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Migration.Core/EmbeddedResources/Migration_17.1_17.2.sql (.../Migration_17.1_17.2.sql) (revision 43403466c934b16bad9ec2960c884b6fad9c9a18)
+++ Application/Ringtoets/src/Application.Ringtoets.Migration.Core/EmbeddedResources/Migration_17.1_17.2.sql (.../Migration_17.1_17.2.sql) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -102,7 +102,25 @@
LEFT JOIN [SOURCEPROJECT].ClosingStructureEntity USING (FailureMechanismEntityId)
LEFT JOIN [SOURCEPROJECT].ForeshoreProfileEntity USING (FailureMechanismEntityId)
GROUP BY FailureMechanismEntityID;
-INSERT INTO ClosingStructuresOutputEntity SELECT * FROM [SOURCEPROJECT].ClosingStructuresOutputEntity;
+INSERT INTO ClosingStructuresOutputEntity(
+ [ClosingStructuresOutputEntityId],
+ [ClosingStructuresCalculationEntityId],
+ [GeneralResultFaultTreeIllustrationPointEntityId],
+ [RequiredProbability],
+ [RequiredReliability],
+ [Probability],
+ [Reliability],
+ [FactorOfSafety])
+SELECT
+ [ClosingStructuresOutputEntityId],
+ [ClosingStructuresCalculationEntityId],
+ NULL,
+ [RequiredProbability],
+ [RequiredReliability],
+ [Probability],
+ [Reliability],
+ [FactorOfSafety]
+ FROM [SOURCEPROJECT].ClosingStructuresOutputEntity;
INSERT INTO ClosingStructuresSectionResultEntity SELECT * FROM [SOURCEPROJECT].ClosingStructuresSectionResultEntity;
INSERT INTO DikeProfileEntity SELECT * FROM [SOURCEPROJECT].DikeProfileEntity;
INSERT INTO DuneErosionFailureMechanismMetaEntity SELECT * FROM [SOURCEPROJECT].DuneErosionFailureMechanismMetaEntity;
@@ -284,7 +302,25 @@
LEFT JOIN [SOURCEPROJECT].HeightStructureEntity USING (FailureMechanismEntityId)
LEFT JOIN [SOURCEPROJECT].ForeshoreProfileEntity USING (FailureMechanismEntityId)
GROUP BY FailureMechanismEntityID;
-INSERT INTO HeightStructuresOutputEntity SELECT * FROM [SOURCEPROJECT].HeightStructuresOutputEntity;
+INSERT INTO HeightStructuresOutputEntity(
+ [HeightStructuresOutputEntityId],
+ [HeightStructuresCalculationEntityId],
+ [GeneralResultFaultTreeIllustrationPointEntityId],
+ [RequiredProbability],
+ [RequiredReliability],
+ [Probability],
+ [Reliability],
+ [FactorOfSafety])
+SELECT
+ [HeightStructuresOutputEntityId],
+ [HeightStructuresCalculationEntityId],
+ NULL,
+ [RequiredProbability],
+ [RequiredReliability],
+ [Probability],
+ [Reliability],
+ [FactorOfSafety]
+ FROM [SOURCEPROJECT].HeightStructuresOutputEntity;
INSERT INTO HeightStructuresSectionResultEntity SELECT * FROM [SOURCEPROJECT].HeightStructuresSectionResultEntity;
INSERT INTO HydraulicLocationEntity (
[HydraulicLocationEntityId],
@@ -498,7 +534,25 @@
LEFT JOIN [SOURCEPROJECT].ForeshoreProfileEntity USING (FailureMechanismEntityId)
LEFT JOIN [SOURCEPROJECT].StabilityPointStructureEntity USING (FailureMechanismEntityId)
GROUP BY FailureMechanismEntityId;
-INSERT INTO StabilityPointStructuresOutputEntity SELECT * FROM [SOURCEPROJECT].StabilityPointStructuresOutputEntity;
+INSERT INTO StabilityPointStructuresOutputEntity(
+ [StabilityPointStructuresOutputEntity],
+ [StabilityPointStructuresCalculationEntityId],
+ [GeneralResultFaultTreeIllustrationPointEntityId],
+ [RequiredProbability],
+ [RequiredReliability],
+ [Probability],
+ [Reliability],
+ [FactorOfSafety])
+SELECT
+ [StabilityPointStructuresOutputEntity],
+ [StabilityPointStructuresCalculationEntityId],
+ NULL,
+ [RequiredProbability],
+ [RequiredReliability],
+ [Probability],
+ [Reliability],
+ [FactorOfSafety]
+ FROM [SOURCEPROJECT].StabilityPointStructuresOutputEntity;
INSERT INTO StabilityPointStructuresSectionResultEntity SELECT * FROM [SOURCEPROJECT].StabilityPointStructuresSectionResultEntity;
INSERT INTO StabilityStoneCoverSectionResultEntity SELECT * FROM [SOURCEPROJECT].StabilityStoneCoverSectionResultEntity;
INSERT INTO StabilityStoneCoverWaveConditionsCalculationEntity SELECT * FROM [SOURCEPROJECT].StabilityStoneCoverWaveConditionsCalculationEntity;
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/Application.Ringtoets.Storage.csproj
===================================================================
diff -u -r21a8bf6970e947dae5febb4ea41d5fbb4d7f30bb -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Storage/Application.Ringtoets.Storage.csproj (.../Application.Ringtoets.Storage.csproj) (revision 21a8bf6970e947dae5febb4ea41d5fbb4d7f30bb)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/Application.Ringtoets.Storage.csproj (.../Application.Ringtoets.Storage.csproj) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -138,9 +138,15 @@
RingtoetsEntities.tt
+
+ RingtoetsEntities.tt
+
RingtoetsEntities.tt
+
+ RingtoetsEntities.tt
+
RingtoetsEntities.tt
@@ -309,6 +315,9 @@
RingtoetsEntities.tt
+
+ RingtoetsEntities.tt
+
RingtoetsEntities.tt
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/ClosingStructuresOutputEntity.cs
===================================================================
diff -u -r3fb0df0ed6e64657154700ee7706e035d5bf99f5 -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/ClosingStructuresOutputEntity.cs (.../ClosingStructuresOutputEntity.cs) (revision 3fb0df0ed6e64657154700ee7706e035d5bf99f5)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/ClosingStructuresOutputEntity.cs (.../ClosingStructuresOutputEntity.cs) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -34,8 +34,10 @@
{
public long ClosingStructuresOutputEntityId { get; set; }
public long ClosingStructuresCalculationEntityId { get; set; }
+ public long? GeneralResultFaultTreeIllustrationPointEntityId { get; set; }
public virtual ClosingStructuresCalculationEntity ClosingStructuresCalculationEntity { get; set; }
+ public virtual GeneralResultFaultTreeIllustrationPointEntity GeneralResultFaultTreeIllustrationPointEntity { get; set; }
public double? RequiredProbability { get; set; }
public double? RequiredReliability { get; set; }
public double? Probability { get; set; }
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/FaultTreeIllustrationPointEntity.cs
===================================================================
diff -u
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/FaultTreeIllustrationPointEntity.cs (revision 0)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/FaultTreeIllustrationPointEntity.cs (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -0,0 +1,68 @@
+// Copyright (C) Stichting Deltares 2017. All rights reserved.
+//
+// This file is part of Ringtoets.
+//
+// Ringtoets is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program. If not, see .
+//
+// All names, logos, and references to "Deltares" are registered trademarks of
+// Stichting Deltares and remain full property of Stichting Deltares at all times.
+// All rights reserved.
+
+//------------------------------------------------------------------------------
+//
+// This code was generated from a template.
+//
+// Manual changes to this file may cause unexpected behavior in your application.
+// Manual changes to this file will be overwritten if the code is regenerated.
+//
+//------------------------------------------------------------------------------
+
+using System.Collections.Generic;
+using System.Diagnostics.CodeAnalysis;
+
+namespace Application.Ringtoets.Storage.DbContext
+{
+ public class FaultTreeIllustrationPointEntity
+ {
+ [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")]
+ public FaultTreeIllustrationPointEntity()
+ {
+ FaultTreeIllustrationPointEntity1 = new HashSet();
+ TopLevelFaultTreeIllustrationPointEntities = new HashSet();
+ StochastEntities = new HashSet();
+ SubMechanismIllustrationPointEntities = new HashSet();
+ }
+
+ public long FaultTreeIllustrationPointEntityId { get; set; }
+ public long? ParentFaultTreeIllustrationPointEntityId { get; set; }
+ public string Name { get; set; }
+ public double Beta { get; set; }
+ public byte CombinationType { get; set; }
+ public int Order { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection FaultTreeIllustrationPointEntity1 { get; set; }
+
+ public virtual FaultTreeIllustrationPointEntity FaultTreeIllustrationPointEntity2 { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection TopLevelFaultTreeIllustrationPointEntities { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection StochastEntities { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection SubMechanismIllustrationPointEntities { get; set; }
+ }
+}
\ No newline at end of file
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/GeneralResultFaultTreeIllustrationPointEntity.cs
===================================================================
diff -u
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/GeneralResultFaultTreeIllustrationPointEntity.cs (revision 0)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/GeneralResultFaultTreeIllustrationPointEntity.cs (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -0,0 +1,67 @@
+// Copyright (C) Stichting Deltares 2017. All rights reserved.
+//
+// This file is part of Ringtoets.
+//
+// Ringtoets is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program. If not, see .
+//
+// All names, logos, and references to "Deltares" are registered trademarks of
+// Stichting Deltares and remain full property of Stichting Deltares at all times.
+// All rights reserved.
+
+//------------------------------------------------------------------------------
+//
+// This code was generated from a template.
+//
+// Manual changes to this file may cause unexpected behavior in your application.
+// Manual changes to this file will be overwritten if the code is regenerated.
+//
+//------------------------------------------------------------------------------
+
+using System.Collections.Generic;
+using System.Diagnostics.CodeAnalysis;
+
+namespace Application.Ringtoets.Storage.DbContext
+{
+ public class GeneralResultFaultTreeIllustrationPointEntity
+ {
+ [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")]
+ public GeneralResultFaultTreeIllustrationPointEntity()
+ {
+ ClosingStructuresOutputEntities = new HashSet();
+ HeightStructuresOutputEntities = new HashSet();
+ StabilityPointStructuresOutputEntities = new HashSet();
+ TopLevelFaultTreeIllustrationPointEntities = new HashSet();
+ StochastEntities = new HashSet();
+ }
+
+ public long GeneralResultFaultTreeIllustrationPointEntityId { get; set; }
+ public string GoverningWindDirectionName { get; set; }
+ public double GoverningWindDirectionAngle { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection ClosingStructuresOutputEntities { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection HeightStructuresOutputEntities { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection StabilityPointStructuresOutputEntities { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection TopLevelFaultTreeIllustrationPointEntities { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection StochastEntities { get; set; }
+ }
+}
\ No newline at end of file
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/HeightStructuresOutputEntity.cs
===================================================================
diff -u -r3fb0df0ed6e64657154700ee7706e035d5bf99f5 -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/HeightStructuresOutputEntity.cs (.../HeightStructuresOutputEntity.cs) (revision 3fb0df0ed6e64657154700ee7706e035d5bf99f5)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/HeightStructuresOutputEntity.cs (.../HeightStructuresOutputEntity.cs) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -34,7 +34,9 @@
{
public long HeightStructuresOutputEntityId { get; set; }
public long HeightStructuresCalculationEntityId { get; set; }
+ public long? GeneralResultFaultTreeIllustrationPointEntityId { get; set; }
+ public virtual GeneralResultFaultTreeIllustrationPointEntity GeneralResultFaultTreeIllustrationPointEntity { get; set; }
public virtual HeightStructuresCalculationEntity HeightStructuresCalculationEntity { get; set; }
public double? RequiredProbability { get; set; }
public double? RequiredReliability { get; set; }
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.Context.cs
===================================================================
diff -u -r6a60e0e3f676c71e253ad41839519c18dd641e9e -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.Context.cs (.../RingtoetsEntities.Context.cs) (revision 6a60e0e3f676c71e253ad41839519c18dd641e9e)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.Context.cs (.../RingtoetsEntities.Context.cs) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -52,7 +52,9 @@
public virtual DbSet DuneLocationOutputEntities { get; set; }
public virtual DbSet FailureMechanismEntities { get; set; }
public virtual DbSet FailureMechanismSectionEntities { get; set; }
+ public virtual DbSet FaultTreeIllustrationPointEntities { get; set; }
public virtual DbSet ForeshoreProfileEntities { get; set; }
+ public virtual DbSet GeneralResultFaultTreeIllustrationPointEntities { get; set; }
public virtual DbSet GeneralResultSubMechanismIllustrationPointEntities { get; set; }
public virtual DbSet GrassCoverErosionInwardsCalculationEntities { get; set; }
public virtual DbSet GrassCoverErosionInwardsDikeHeightOutputEntities { get; set; }
@@ -105,6 +107,7 @@
public virtual DbSet SubMechanismIllustrationPointStochastEntities { get; set; }
public virtual DbSet SurfaceLineEntities { get; set; }
public virtual DbSet TechnicalInnovationSectionResultEntities { get; set; }
+ public virtual DbSet TopLevelFaultTreeIllustrationPointEntities { get; set; }
public virtual DbSet TopLevelSubMechanismIllustrationPointEntities { get; set; }
public virtual DbSet VersionEntities { get; set; }
public virtual DbSet WaterPressureAsphaltCoverSectionResultEntities { get; set; }
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.Designer.cs
===================================================================
diff -u -rc0467a5ee5f6d7163ce9d8ba61fc8b22828bb44e -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.Designer.cs (.../RingtoetsEntities.Designer.cs) (revision c0467a5ee5f6d7163ce9d8ba61fc8b22828bb44e)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.Designer.cs (.../RingtoetsEntities.Designer.cs) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -19,7 +19,7 @@
// Stichting Deltares and remain full property of Stichting Deltares at all times.
// All rights reserved.
-// T4 code generation is enabled for model 'D:\WTI\Application\Ringtoets\src\Application.Ringtoets.Storage\DbContext\RingtoetsEntities.edmx'.
+// T4 code generation is enabled for model 'D:\Projects\WTITrunk\Application\Ringtoets\src\Application.Ringtoets.Storage\DbContext\RingtoetsEntities.edmx'.
// To enable legacy code generation, change the value of the 'Code Generation Strategy' designer
// property to 'Legacy ObjectContext'. This property is available in the Properties Window when the model
// is open in the designer.
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx
===================================================================
diff -u -r43403466c934b16bad9ec2960c884b6fad9c9a18 -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx (.../RingtoetsEntities.edmx) (revision 43403466c934b16bad9ec2960c884b6fad9c9a18)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx (.../RingtoetsEntities.edmx) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -4,7 +4,7 @@
-
+
@@ -161,6 +161,7 @@
+
@@ -267,6 +268,33 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -284,6 +312,22 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -566,6 +610,7 @@
+
@@ -919,6 +964,7 @@
+
@@ -1076,6 +1122,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
@@ -1297,6 +1355,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
@@ -1428,6 +1498,66 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -1440,6 +1570,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -1788,6 +1942,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
@@ -2100,6 +2266,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
@@ -2280,6 +2458,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -2406,7 +2608,12 @@
+
+
+
+
+
@@ -2460,6 +2667,7 @@
+
@@ -2512,6 +2720,10 @@
+
+
+
+
@@ -2555,10 +2767,38 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -2675,6 +2915,10 @@
+
+
+
+
@@ -2779,6 +3023,10 @@
+
+
+
+
@@ -2839,6 +3087,14 @@
+
+
+
+
+
+
+
+
@@ -2898,7 +3154,9 @@
+
+
@@ -2951,6 +3209,7 @@
+
@@ -3038,7 +3297,7 @@
-
+
@@ -3050,6 +3309,10 @@
+
+
+
+
@@ -3198,6 +3461,14 @@
+
+
+
+
+
+
+
+
@@ -3218,6 +3489,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
@@ -3358,6 +3641,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
@@ -3527,7 +3822,7 @@
-
+
@@ -3547,12 +3842,14 @@
+
-
+
+
@@ -3703,6 +4000,22 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -3727,6 +4040,19 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -4041,11 +4367,13 @@
+
+
@@ -4436,11 +4764,13 @@
+
+
@@ -4530,6 +4860,8 @@
+
+
@@ -4579,6 +4911,7 @@
+
@@ -4618,6 +4951,20 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -4956,7 +5303,7 @@
-
+
@@ -4992,6 +5339,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
@@ -5436,6 +5795,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -5496,6 +5879,42 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -5916,6 +6335,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
@@ -6092,6 +6523,7 @@
+
@@ -6205,6 +6637,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
@@ -6223,6 +6667,15 @@
+
+
+
+
+
+
+
+
+
@@ -6517,6 +6970,7 @@
+
@@ -6890,6 +7344,7 @@
+
@@ -7059,6 +7514,19 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -7154,6 +7622,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx.diagram
===================================================================
diff -u -r43403466c934b16bad9ec2960c884b6fad9c9a18 -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx.diagram (.../RingtoetsEntities.edmx.diagram) (revision 43403466c934b16bad9ec2960c884b6fad9c9a18)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx.diagram (.../RingtoetsEntities.edmx.diagram) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -6,82 +6,85 @@
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -102,9 +105,10 @@
-
+
+
@@ -142,11 +146,16 @@
+
+
+
+
+
@@ -182,6 +191,9 @@
+
+
+
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/StabilityPointStructuresOutputEntity.cs
===================================================================
diff -u -r3fb0df0ed6e64657154700ee7706e035d5bf99f5 -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/StabilityPointStructuresOutputEntity.cs (.../StabilityPointStructuresOutputEntity.cs) (revision 3fb0df0ed6e64657154700ee7706e035d5bf99f5)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/StabilityPointStructuresOutputEntity.cs (.../StabilityPointStructuresOutputEntity.cs) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -34,7 +34,9 @@
{
public long StabilityPointStructuresOutputEntity1 { get; set; }
public long StabilityPointStructuresCalculationEntityId { get; set; }
+ public long? GeneralResultFaultTreeIllustrationPointEntityId { get; set; }
+ public virtual GeneralResultFaultTreeIllustrationPointEntity GeneralResultFaultTreeIllustrationPointEntity { get; set; }
public virtual StabilityPointStructuresCalculationEntity StabilityPointStructuresCalculationEntity { get; set; }
public double? RequiredProbability { get; set; }
public double? RequiredReliability { get; set; }
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/StochastEntity.cs
===================================================================
diff -u -r6a60e0e3f676c71e253ad41839519c18dd641e9e -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/StochastEntity.cs (.../StochastEntity.cs) (revision 6a60e0e3f676c71e253ad41839519c18dd641e9e)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/StochastEntity.cs (.../StochastEntity.cs) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -38,6 +38,8 @@
[SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")]
public StochastEntity()
{
+ FaultTreeIllustrationPointEntities = new HashSet();
+ GeneralResultFaultTreeIllustrationPointEntities = new HashSet();
GeneralResultSubMechanismIllustrationPointEntities = new HashSet();
}
@@ -48,6 +50,12 @@
public int Order { get; set; }
[SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection FaultTreeIllustrationPointEntities { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection GeneralResultFaultTreeIllustrationPointEntities { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
public virtual ICollection GeneralResultSubMechanismIllustrationPointEntities { get; set; }
}
}
\ No newline at end of file
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/SubMechanismIllustrationPointEntity.cs
===================================================================
diff -u -r6a60e0e3f676c71e253ad41839519c18dd641e9e -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/SubMechanismIllustrationPointEntity.cs (.../SubMechanismIllustrationPointEntity.cs) (revision 6a60e0e3f676c71e253ad41839519c18dd641e9e)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/SubMechanismIllustrationPointEntity.cs (.../SubMechanismIllustrationPointEntity.cs) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -41,6 +41,7 @@
IllustrationPointResultEntities = new HashSet();
SubMechanismIllustrationPointStochastEntities = new HashSet();
TopLevelSubMechanismIllustrationPointEntities = new HashSet();
+ FaultTreeIllustrationPointEntities = new HashSet();
}
public long SubMechanismIllustrationPointEntityId { get; set; }
@@ -56,5 +57,8 @@
[SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
public virtual ICollection TopLevelSubMechanismIllustrationPointEntities { get; set; }
+
+ [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
+ public virtual ICollection FaultTreeIllustrationPointEntities { get; set; }
}
}
\ No newline at end of file
Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/TopLevelFaultTreeIllustrationPointEntity.cs
===================================================================
diff -u
--- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/TopLevelFaultTreeIllustrationPointEntity.cs (revision 0)
+++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/TopLevelFaultTreeIllustrationPointEntity.cs (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -0,0 +1,46 @@
+// Copyright (C) Stichting Deltares 2017. All rights reserved.
+//
+// This file is part of Ringtoets.
+//
+// Ringtoets is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program. If not, see .
+//
+// All names, logos, and references to "Deltares" are registered trademarks of
+// Stichting Deltares and remain full property of Stichting Deltares at all times.
+// All rights reserved.
+
+//------------------------------------------------------------------------------
+//
+// This code was generated from a template.
+//
+// Manual changes to this file may cause unexpected behavior in your application.
+// Manual changes to this file will be overwritten if the code is regenerated.
+//
+//------------------------------------------------------------------------------
+
+namespace Application.Ringtoets.Storage.DbContext
+{
+ public class TopLevelFaultTreeIllustrationPointEntity
+ {
+ public long TopLevelFaultTreeIllustrationPointEntityId { get; set; }
+ public long FaultTreeIllustrationPointEntityId { get; set; }
+ public long GeneralResultFaultTreeIllustrationPointEntityId { get; set; }
+ public string ClosingSituation { get; set; }
+ public string WindDirectionName { get; set; }
+ public double WindDirectionAngle { get; set; }
+ public int Order { get; set; }
+
+ public virtual FaultTreeIllustrationPointEntity FaultTreeIllustrationPointEntity { get; set; }
+ public virtual GeneralResultFaultTreeIllustrationPointEntity GeneralResultFaultTreeIllustrationPointEntity { get; set; }
+ }
+}
\ No newline at end of file
Index: build/DatabaseStructure.sql
===================================================================
diff -u -r43403466c934b16bad9ec2960c884b6fad9c9a18 -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
--- build/DatabaseStructure.sql (.../DatabaseStructure.sql) (revision 43403466c934b16bad9ec2960c884b6fad9c9a18)
+++ build/DatabaseStructure.sql (.../DatabaseStructure.sql) (revision e6a591b93ec33becef19b4d71f3d49de0fbd7f10)
@@ -1,15 +1,15 @@
/* ---------------------------------------------------- */
/* Generated by Enterprise Architect Version 12.0 */
-/* Created On : 05-Jul-2017 11:39:12 */
+/* Created On : 13-Jul-2017 2:06:57 PM */
/* DBMS : SQLite */
/* ---------------------------------------------------- */
/* Drop Tables */
-DROP TABLE IF EXISTS 'VersionEntity'
+DROP TABLE IF EXISTS 'GrassCoverErosionInwardsDikeHeightOutputEntity'
;
-DROP TABLE IF EXISTS 'GrassCoverErosionInwardsDikeHeightOutputEntity'
+DROP TABLE IF EXISTS 'VersionEntity'
;
DROP TABLE IF EXISTS 'ProjectEntity'
@@ -36,24 +36,24 @@
DROP TABLE IF EXISTS 'ClosingStructuresFailureMechanismMetaEntity'
;
-DROP TABLE IF EXISTS 'CalculationGroupEntity'
-;
-
DROP TABLE IF EXISTS 'StabilityPointStructuresFailureMechanismMetaEntity'
;
-DROP TABLE IF EXISTS 'DuneErosionFailureMechanismMetaEntity'
+DROP TABLE IF EXISTS 'CalculationGroupEntity'
;
DROP TABLE IF EXISTS 'HydraulicLocationEntity'
;
-DROP TABLE IF EXISTS 'PipingCalculationEntity'
+DROP TABLE IF EXISTS 'DuneErosionFailureMechanismMetaEntity'
;
DROP TABLE IF EXISTS 'GrassCoverErosionInwardsFailureMechanismMetaEntity'
;
+DROP TABLE IF EXISTS 'PipingCalculationEntity'
+;
+
DROP TABLE IF EXISTS 'HeightStructuresFailureMechanismMetaEntity'
;
@@ -234,23 +234,32 @@
DROP TABLE IF EXISTS 'GeneralResultSubMechanismIllustrationPointStochastEntity'
;
+DROP TABLE IF EXISTS 'GeneralResultFaultTreeIllustrationPointEntity'
+;
+
+DROP TABLE IF EXISTS 'FaultTreeIllustrationPointEntity'
+;
+
+DROP TABLE IF EXISTS 'FaultTreeIllustrationPointStochastEntity'
+;
+
+DROP TABLE IF EXISTS 'GeneralResultFaultTreeIllustrationPointStochastEntity'
+;
+
DROP TABLE IF EXISTS 'TopLevelSubMechanismIllustrationPointEntity'
;
+DROP TABLE IF EXISTS 'TopLevelFaultTreeIllustrationPointEntity'
+;
+
DROP TABLE IF EXISTS 'SubMechanismIllustrationPointStochastEntity'
;
-/* Create Tables with Primary and Foreign Keys, Check and Unique Constraints */
-
-CREATE TABLE 'VersionEntity'
-(
- 'VersionId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- 'Version' VARCHAR (20) NOT NULL,
- 'Timestamp' DATETIME NOT NULL,
- 'FingerPrint' BLOB NOT NULL
-)
+DROP TABLE IF EXISTS 'FaultTreeSubmechanismIllustrationPointEntity'
;
+/* Create Tables with Primary and Foreign Keys, Check and Unique Constraints */
+
CREATE TABLE 'GrassCoverErosionInwardsDikeHeightOutputEntity'
(
'GrassCoverErosionInwardsDikeHeightOutputEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -266,6 +275,15 @@
)
;
+CREATE TABLE 'VersionEntity'
+(
+ 'VersionId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'Version' VARCHAR (20) NOT NULL,
+ 'Timestamp' DATETIME NOT NULL,
+ 'FingerPrint' BLOB NOT NULL
+)
+;
+
CREATE TABLE 'ProjectEntity'
(
'ProjectEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -420,16 +438,6 @@
)
;
-CREATE TABLE 'CalculationGroupEntity'
-(
- 'CalculationGroupEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- 'ParentCalculationGroupEntityId' INTEGER,
- 'Name' VARCHAR (260),
- 'Order' INT (4) NOT NULL,
- CONSTRAINT 'FK_CalculationGroupEntity_CalculationGroupEntity' FOREIGN KEY ('ParentCalculationGroupEntityId') REFERENCES 'CalculationGroupEntity' ('CalculationGroupEntityId') ON DELETE Cascade ON UPDATE Cascade
-)
-;
-
CREATE TABLE 'StabilityPointStructuresFailureMechanismMetaEntity'
(
'StabilityPointStructuresFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -441,12 +449,13 @@
)
;
-CREATE TABLE 'DuneErosionFailureMechanismMetaEntity'
+CREATE TABLE 'CalculationGroupEntity'
(
- 'DuneErosionFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- 'FailureMechanismEntityId' INTEGER NOT NULL,
- 'N' REAL NOT NULL,
- CONSTRAINT 'FK_DuneErosionFailureMechanismMetaEntity_FailureMechanismEntity' FOREIGN KEY ('FailureMechanismEntityId') REFERENCES 'FailureMechanismEntity' ('FailureMechanismEntityId') ON DELETE Cascade ON UPDATE Cascade
+ 'CalculationGroupEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'ParentCalculationGroupEntityId' INTEGER,
+ 'Name' VARCHAR (260),
+ 'Order' INT (4) NOT NULL,
+ CONSTRAINT 'FK_CalculationGroupEntity_CalculationGroupEntity' FOREIGN KEY ('ParentCalculationGroupEntityId') REFERENCES 'CalculationGroupEntity' ('CalculationGroupEntityId') ON DELETE Cascade ON UPDATE Cascade
)
;
@@ -465,6 +474,25 @@
)
;
+CREATE TABLE 'DuneErosionFailureMechanismMetaEntity'
+(
+ 'DuneErosionFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'FailureMechanismEntityId' INTEGER NOT NULL,
+ 'N' REAL NOT NULL,
+ CONSTRAINT 'FK_DuneErosionFailureMechanismMetaEntity_FailureMechanismEntity' FOREIGN KEY ('FailureMechanismEntityId') REFERENCES 'FailureMechanismEntity' ('FailureMechanismEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
+CREATE TABLE 'GrassCoverErosionInwardsFailureMechanismMetaEntity'
+(
+ 'GrassCoverErosionInwardsFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'FailureMechanismEntityId' INTEGER NOT NULL,
+ 'N' INT (4) NOT NULL,
+ 'DikeProfileCollectionSourcePath' TEXT,
+ CONSTRAINT 'FK_GrassCoverErosionInwardsFailureMechanismMetaEntity_FailureMechanismEntity' FOREIGN KEY ('FailureMechanismEntityId') REFERENCES 'FailureMechanismEntity' ('FailureMechanismEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
CREATE TABLE 'PipingCalculationEntity'
(
'PipingCalculationEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -492,16 +520,6 @@
)
;
-CREATE TABLE 'GrassCoverErosionInwardsFailureMechanismMetaEntity'
-(
- 'GrassCoverErosionInwardsFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- 'FailureMechanismEntityId' INTEGER NOT NULL,
- 'N' INT (4) NOT NULL,
- 'DikeProfileCollectionSourcePath' TEXT,
- CONSTRAINT 'FK_GrassCoverErosionInwardsFailureMechanismMetaEntity_FailureMechanismEntity' FOREIGN KEY ('FailureMechanismEntityId') REFERENCES 'FailureMechanismEntity' ('FailureMechanismEntityId') ON DELETE Cascade ON UPDATE Cascade
-)
-;
-
CREATE TABLE 'HeightStructuresFailureMechanismMetaEntity'
(
'HeightStructuresFailureMechanismMetaEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -1088,11 +1106,13 @@
(
'HeightStructuresOutputEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
'HeightStructuresCalculationEntityId' INTEGER NOT NULL,
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER,
'RequiredProbability' REAL,
'RequiredReliability' REAL,
'Probability' REAL,
'Reliability' REAL,
'FactorOfSafety' REAL,
+ CONSTRAINT 'FK_HeightStructuresOutputEntity_GeneralResultFaultTreeIllustrationPointEntity' FOREIGN KEY ('GeneralResultFaultTreeIllustrationPointEntityId') REFERENCES 'GeneralResultFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId') ON DELETE Set Null ON UPDATE Cascade,
CONSTRAINT 'FK_HeightStructuresOutputEntity_HeightStructuresCalculationEntity' FOREIGN KEY ('HeightStructuresCalculationEntityId') REFERENCES 'HeightStructuresCalculationEntity' ('HeightStructuresCalculationEntityId') ON DELETE Cascade ON UPDATE Cascade,
CONSTRAINT 'U_HeightStructuresCalculationEntity' UNIQUE ('HeightStructuresCalculationEntityId')
)
@@ -1258,12 +1278,14 @@
(
'ClosingStructuresOutputEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
'ClosingStructuresCalculationEntityId' INTEGER NOT NULL,
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER,
'RequiredProbability' REAL,
'RequiredReliability' REAL,
'Probability' REAL,
'Reliability' REAL,
'FactorOfSafety' REAL,
CONSTRAINT 'FK_ClosingStructuresOutputEntity_ClosingStructuresCalculationEntity' FOREIGN KEY ('ClosingStructuresCalculationEntityId') REFERENCES 'ClosingStructuresCalculationEntity' ('ClosingStructuresCalculationEntityId') ON DELETE Cascade ON UPDATE Cascade,
+ CONSTRAINT 'FK_ClosingStructuresOutputEntity_GeneralResultFaultTreeIllustrationPointEntity' FOREIGN KEY ('GeneralResultFaultTreeIllustrationPointEntityId') REFERENCES 'GeneralResultFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId') ON DELETE Set Null ON UPDATE Cascade,
CONSTRAINT 'U_ClosingStructuresCalculationEntity' UNIQUE ('ClosingStructuresCalculationEntityId')
)
;
@@ -1330,11 +1352,13 @@
(
'StabilityPointStructuresOutputEntity' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
'StabilityPointStructuresCalculationEntityId' INTEGER NOT NULL,
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER,
'RequiredProbability' REAL,
'RequiredReliability' REAL,
'Probability' REAL,
'Reliability' REAL,
'FactorOfSafety' REAL,
+ CONSTRAINT 'FK_StabilityPointStructuresOutputEntity_GeneralResultFaultTreeIllustrationPointEntity' FOREIGN KEY ('GeneralResultFaultTreeIllustrationPointEntityId') REFERENCES 'GeneralResultFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId') ON DELETE Set Null ON UPDATE Cascade,
CONSTRAINT 'FK_StabilityPointStructuresOutputEntity_StabilityPointStructuresCalculationEntity' FOREIGN KEY ('StabilityPointStructuresCalculationEntityId') REFERENCES 'StabilityPointStructuresCalculationEntity' ('StabilityPointStructuresCalculationEntityId') ON DELETE Cascade ON UPDATE Cascade,
CONSTRAINT 'U_StabilityPointStructuresCalculationEntity' UNIQUE ('StabilityPointStructuresCalculationEntityId')
)
@@ -1352,7 +1376,7 @@
'CalculatedProbability' REAL,
'CalculatedReliability' REAL,
'CalculationConvergence' TINYINT (1) NOT NULL, -- Enum: 1 = NotCalculated, 2 = CalculatedNotConverged, 3 = CalculatedConverged
- CONSTRAINT 'FK_HydraulicLocationOutputEntity_GeneralResultSubMechanismIllustrationPointEntity' FOREIGN KEY ('GeneralResultSubMechanismIllustrationPointEntityId') REFERENCES 'GeneralResultSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId') ON DELETE No Action ON UPDATE No Action,
+ CONSTRAINT 'FK_HydraulicLocationOutputEntity_GeneralResultSubMechanismIllustrationPointEntity' FOREIGN KEY ('GeneralResultSubMechanismIllustrationPointEntityId') REFERENCES 'GeneralResultSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId') ON DELETE Set Null ON UPDATE Cascade,
CONSTRAINT 'FK_HydraulicLocationOutputEntity_HydraulicLocationEntity' FOREIGN KEY ('HydraulicLocationEntityId') REFERENCES 'HydraulicLocationEntity' ('HydraulicLocationEntityId') ON DELETE Cascade ON UPDATE Cascade,
CONSTRAINT 'U_HydraulicLocationEntityOutputType' UNIQUE ('HydraulicLocationEntityId','HydraulicLocationOutputType')
)
@@ -1370,7 +1394,7 @@
'CalculatedProbability' REAL,
'CalculatedReliability' REAL,
'CalculationConvergence' TINYINT (1) NOT NULL, -- Enum: 1 = NotCalculated, 2 = CalculatedNotConverged, 3 = CalculatedConverged
- CONSTRAINT 'FK_GrassCoverErosionOutwardsHydraulicLocationOutputEntity_GeneralResultSubMechanismIllustrationPointEntity' FOREIGN KEY ('GeneralResultSubMechanismIllustrationPointEntityId') REFERENCES 'GeneralResultSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId') ON DELETE No Action ON UPDATE No Action,
+ CONSTRAINT 'FK_GrassCoverErosionOutwardsHydraulicLocationOutputEntity_GeneralResultSubMechanismIllustrationPointEntity' FOREIGN KEY ('GeneralResultSubMechanismIllustrationPointEntityId') REFERENCES 'GeneralResultSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId') ON DELETE Set Null ON UPDATE Cascade,
CONSTRAINT 'FK_GrassCoverErosionOutwardsHydraulicLocationOutputEntity_GrassCoverErosionOutwardsHydraulicLocationEntity' FOREIGN KEY ('GrassCoverErosionOutwardsHydraulicLocationEntityId') REFERENCES 'GrassCoverErosionOutwardsHydraulicLocationEntity' ('GrassCoverErosionOutwardsHydraulicLocationEntityId') ON DELETE Cascade ON UPDATE Cascade,
CONSTRAINT 'U_HydraulicLocationOutputType' UNIQUE ('GrassCoverErosionOutwardsHydraulicLocationEntityId','HydraulicLocationOutputType')
)
@@ -1491,10 +1515,50 @@
'StochastEntityId' INTEGER NOT NULL,
CONSTRAINT 'PK_GeneralResultSubMechanismIllustrationPointStochastEntity' PRIMARY KEY ('GeneralResultSubMechanismIllustrationPointEntityId','StochastEntityId'),
CONSTRAINT 'FK_GeneralResultSubMechanisIllustrationPointStochastEntity_GeneralResultSubMechanismIllustrationPointEntity' FOREIGN KEY ('GeneralResultSubMechanismIllustrationPointEntityId') REFERENCES 'GeneralResultSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade,
- CONSTRAINT 'FK_GeneralResultSubMechanismIllustrationPointStochastEntity_StochastEntity' FOREIGN KEY ('StochastEntityId') REFERENCES 'StochastEntity' ('StochastEntityId') ON DELETE No Action ON UPDATE No Action
+ CONSTRAINT 'FK_GeneralResultSubMechanismIllustrationPointStochastEntity_StochastEntity' FOREIGN KEY ('StochastEntityId') REFERENCES 'StochastEntity' ('StochastEntityId') ON DELETE Cascade ON UPDATE Cascade
)
;
+CREATE TABLE 'GeneralResultFaultTreeIllustrationPointEntity'
+(
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'GoverningWindDirectionName' TEXT NOT NULL,
+ 'GoverningWindDirectionAngle' REAL NOT NULL
+)
+;
+
+CREATE TABLE 'FaultTreeIllustrationPointEntity'
+(
+ 'FaultTreeIllustrationPointEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'ParentFaultTreeIllustrationPointEntityId' INTEGER,
+ 'Name' TEXT NOT NULL,
+ 'Beta' REAL NOT NULL,
+ 'CombinationType' TINYINT (1) NOT NULL, -- Enum: 1 = Or, 2 = And
+ 'Order' INT (4) NOT NULL,
+ CONSTRAINT 'FK_FaultTreeIllustrationPoint_FaultTreeIllustrationPoint' FOREIGN KEY ('ParentFaultTreeIllustrationPointEntityId') REFERENCES 'FaultTreeIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
+CREATE TABLE 'FaultTreeIllustrationPointStochastEntity'
+(
+ 'FaultTreeIllustrationPointEntityId' INTEGER NOT NULL,
+ 'StochastEntityId' INTEGER NOT NULL,
+ CONSTRAINT 'PK_FaultTreeIllustrationPointStochastEntity' PRIMARY KEY ('FaultTreeIllustrationPointEntityId','StochastEntityId'),
+ CONSTRAINT 'FK_FaultTreeIllustrationPointStochastEntity_FaultTreeIllustrationPoint' FOREIGN KEY ('FaultTreeIllustrationPointEntityId') REFERENCES 'FaultTreeIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId') ON DELETE No Action ON UPDATE No Action,
+ CONSTRAINT 'FK_FaultTreeIllustrationPointStochastEntity_StochastEntity' FOREIGN KEY ('StochastEntityId') REFERENCES 'StochastEntity' ('StochastEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
+CREATE TABLE 'GeneralResultFaultTreeIllustrationPointStochastEntity'
+(
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER NOT NULL,
+ 'StochastEntityId' INTEGER NOT NULL,
+ CONSTRAINT 'PK_GeneralResultFaultTreeIllustrationPointStochastEntity' PRIMARY KEY ('GeneralResultFaultTreeIllustrationPointEntityId','StochastEntityId'),
+ CONSTRAINT 'FK_GeneralResultFaultTreeIllustrationPointStochastEntity_GeneralResultFaultTreeIllustrationPointEntity' FOREIGN KEY ('GeneralResultFaultTreeIllustrationPointEntityId') REFERENCES 'GeneralResultFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade,
+ CONSTRAINT 'FK_GeneralResultFaultTreeIllustrationPointStochastEntity_StochastEntity' FOREIGN KEY ('StochastEntityId') REFERENCES 'StochastEntity' ('StochastEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
CREATE TABLE 'TopLevelSubMechanismIllustrationPointEntity'
(
'TopLevelSubMechanismIllustrationPointEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -1509,6 +1573,20 @@
)
;
+CREATE TABLE 'TopLevelFaultTreeIllustrationPointEntity'
+(
+ 'TopLevelFaultTreeIllustrationPointEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
+ 'FaultTreeIllustrationPointEntityId' INTEGER NOT NULL,
+ 'GeneralResultFaultTreeIllustrationPointEntityId' INTEGER NOT NULL,
+ 'ClosingSituation' TEXT NOT NULL,
+ 'WindDirectionName' TEXT NOT NULL,
+ 'WindDirectionAngle' REAL NOT NULL,
+ 'Order' INT (4) NOT NULL,
+ CONSTRAINT 'FK_TopLevelFaultTreeIllustrationPointEntity_FaultTreeIllustrationPointEntity' FOREIGN KEY ('FaultTreeIllustrationPointEntityId') REFERENCES 'FaultTreeIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade,
+ CONSTRAINT 'FK_TopLevelFaultTreeIllustrationPointEntity_GeneralResultFaultTreeIllustrationPointEntity' FOREIGN KEY ('GeneralResultFaultTreeIllustrationPointEntityId') REFERENCES 'GeneralResultFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
CREATE TABLE 'SubMechanismIllustrationPointStochastEntity'
(
'SubMechanismIllustrationPointStochastEntityId' INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
@@ -1522,6 +1600,16 @@
)
;
+CREATE TABLE 'FaultTreeSubmechanismIllustrationPointEntity'
+(
+ 'SubMechanismIllustrationPointEntityId' INTEGER NOT NULL,
+ 'FaultTreeIllustrationPointEntityId' INTEGER NOT NULL,
+ CONSTRAINT 'PK_FaultTreeSubMechanismIllustrationPointEntityId' PRIMARY KEY ('SubMechanismIllustrationPointEntityId','FaultTreeIllustrationPointEntityId'),
+ CONSTRAINT 'FK_FaultTreeIllustrationPointEntity_FaultTreeIllustrationPointEntity' FOREIGN KEY ('FaultTreeIllustrationPointEntityId') REFERENCES 'FaultTreeIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade,
+ CONSTRAINT 'FK_FaultTreeIllustrationPointEntity_SubMechanismIllustrationPointEntity' FOREIGN KEY ('SubMechanismIllustrationPointEntityId') REFERENCES 'SubMechanismIllustrationPointEntity' ('SubMechanismIllustrationPointEntityId') ON DELETE Cascade ON UPDATE Cascade
+)
+;
+
/* Create Indexes and Triggers */
CREATE INDEX 'IXFK_GrassCoverErosionInwardsDikeHeightOutputEntity_GrassCoverErosionInwardsOutputEntity'
@@ -1572,20 +1660,24 @@
ON 'ClosingStructuresFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
;
+CREATE INDEX 'IXFK_StrengthStabilityPointConstructionFailureMechanismMetaEntity_FailureMechanismEntity'
+ ON 'StabilityPointStructuresFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
+;
+
CREATE INDEX 'IXFK_CalculationGroupEntity_CalculationGroupEntity'
ON 'CalculationGroupEntity' ('ParentCalculationGroupEntityId' ASC)
;
-CREATE INDEX 'IXFK_StrengthStabilityPointConstructionFailureMechanismMetaEntity_FailureMechanismEntity'
- ON 'StabilityPointStructuresFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
+CREATE INDEX 'IXFK_HydraulicLocationEntity_AssessmentSectionEntity'
+ ON 'HydraulicLocationEntity' ('AssessmentSectionEntityId' ASC)
;
CREATE INDEX 'IXFK_DuneErosionFailureMechanismMetaEntity_FailureMechanismEntity'
ON 'DuneErosionFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
;
-CREATE INDEX 'IXFK_HydraulicLocationEntity_AssessmentSectionEntity'
- ON 'HydraulicLocationEntity' ('AssessmentSectionEntityId' ASC)
+CREATE INDEX 'IXFK_GrassCoverErosionInwardsFailureMechanismMetaEntity_FailureMechanismEntity'
+ ON 'GrassCoverErosionInwardsFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
;
CREATE INDEX 'IXFK_PipingCalculationEntity_StochasticSoilProfileEntity'
@@ -1604,10 +1696,6 @@
ON 'PipingCalculationEntity' ('CalculationGroupEntityId' ASC)
;
-CREATE INDEX 'IXFK_GrassCoverErosionInwardsFailureMechanismMetaEntity_FailureMechanismEntity'
- ON 'GrassCoverErosionInwardsFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
-;
-
CREATE INDEX 'IXFK_HeightStructuresFailureMechanismMetaEntity_FailureMechanismEntity'
ON 'HeightStructuresFailureMechanismMetaEntity' ('FailureMechanismEntityId' ASC)
;
@@ -1946,6 +2034,48 @@
END;
;
+CREATE INDEX 'IXFK_FaultTreeIllustrationPoint_FaultTreeIllustrationPoint'
+ ON 'FaultTreeIllustrationPointEntity' ('ParentFaultTreeIllustrationPointEntityId' ASC)
+;
+
+CREATE INDEX 'IXFK_FaultTreeIllustrationPointStochastEntity_FaultTreeIllustrationPoint'
+ ON 'FaultTreeIllustrationPointStochastEntity' ('FaultTreeIllustrationPointEntityId' ASC)
+;
+
+CREATE INDEX 'IXFK_FaultTreeIllustrationPointStochastEntity_StochastEntity'
+ ON 'FaultTreeIllustrationPointStochastEntity' ('StochastEntityId' ASC)
+;
+CREATE TRIGGER [TR_AfterDeleteFaultTreeIllustrationPointStochastEntity_RemoveStochastEntity]
+ AFTER DELETE
+ ON FaultTreeIllustrationPointStochastEntity
+ FOR EACH ROW
+BEGIN
+ DELETE
+ FROM StochastEntity
+ WHERE OLD.StochastEntityId IS NOT NULL
+ AND StochastEntityId IS OLD.StochastEntityId;
+END;
+;
+
+CREATE INDEX 'IXFK_GeneralResultFaultTreeIllustrationPointStochastEntity_GeneralResultFaultTreeIllustrationPointEntity'
+ ON 'GeneralResultFaultTreeIllustrationPointStochastEntity' ('GeneralResultFaultTreeIllustrationPointEntityId' ASC)
+;
+
+CREATE INDEX 'IXFK_GeneralResultFaultTreeIllustrationPointStochastEntity_StochastEntity'
+ ON 'GeneralResultFaultTreeIllustrationPointStochastEntity' ('StochastEntityId' ASC)
+;
+CREATE TRIGGER [TR_AfterDeleteGeneralResultFaultTreeIllustrationPointStochastEntity_RemoveStochastEntity]
+ AFTER DELETE
+ ON GeneralResultFaultTreeIllustrationPointStochastEntity
+ FOR EACH ROW
+BEGIN
+ DELETE
+ FROM StochastEntity
+ WHERE OLD.StochastEntityId IS NOT NULL
+ AND StochastEntityId IS OLD.StochastEntityId;
+END;
+;
+
CREATE INDEX 'IXFK_TopLevelSubMechanismIllustrationPointEntity_GeneralResultSubMechanismIllustrationPointEntity'
ON 'TopLevelSubMechanismIllustrationPointEntity' ('GeneralResultSubMechanismIllustrationPointEntityId' ASC)
;
@@ -1964,6 +2094,42 @@
END;
;
+CREATE INDEX 'IXFK_TopLevelFaultTreeIllustrationPointEntity_FaultTreeIllustrationPointEntity'
+ ON 'TopLevelFaultTreeIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId' ASC)
+;
+
+CREATE INDEX 'IXFK_TopLevelFaultTreeIllustrationPointEntity_GeneralResultFaultTreeIllustrationPointEntity'
+ ON 'TopLevelFaultTreeIllustrationPointEntity' ('GeneralResultFaultTreeIllustrationPointEntityId' ASC)
+;
+CREATE TRIGGER [TR_AfterDeleteTopLevelFaultTreeIllustrationPointEntity_RemoveFaultTreeIllustrationPointEntity]
+ AFTER DELETE
+ ON TopLevelFaultTreeIllustrationPointEntity
+ FOR EACH ROW
+BEGIN
+ DELETE FROM FaultTreeIllustrationPointEntity
+ WHERE OLD.FaultTreeIllustrationPointEntityId IS NOT NULL AND
+ FaultTreeIllustrationPointEntityId IS OLD.FaultTreeIllustrationPointEntityId;
+END;
+;
+
CREATE INDEX 'IXFK_SubMechanismIllustrationPointStochast_SubMechanismIllustrationPointEntity'
ON 'SubMechanismIllustrationPointStochastEntity' ('SubMechanismIllustrationPointEntityId' ASC)
;
+
+CREATE INDEX 'IXFK_FaultTreeIllustrationPointEntity_FaultTreeIllustrationPointEntity'
+ ON 'FaultTreeSubmechanismIllustrationPointEntity' ('FaultTreeIllustrationPointEntityId' ASC)
+;
+
+CREATE INDEX 'IXFK_FaultTreeIllustrationPointEntity_SubMechanismIllustrationPointEntity'
+ ON 'FaultTreeSubmechanismIllustrationPointEntity' ('SubMechanismIllustrationPointEntityId' ASC)
+;
+CREATE TRIGGER [TR_AfterDeleteFaultTreeSubmechanismIllustrationPointEntity_RemoveSubmechanismIllustrationPointEntity]
+ AFTER DELETE
+ ON FaultTreeSubmechanismIllustrationPointEntity
+ FOR EACH ROW
+BEGIN
+ DELETE FROM SubmechanismIllustrationPointEntity
+ WHERE OLD.SubmechanismIllustrationPointEntityId IS NOT NULL AND
+ SubmechanismIllustrationPointEntityId IS OLD.SubmechanismIllustrationPointEntityId;
+END;
+;
Index: design/DatabaseDesign.eap
===================================================================
diff -u -r43403466c934b16bad9ec2960c884b6fad9c9a18 -re6a591b93ec33becef19b4d71f3d49de0fbd7f10
Binary files differ