From 40c2883914ccf35683a968a93e571c853e4100de Mon Sep 17 00:00:00 2001 From: nnikolopoulos Date: Wed, 12 Apr 2023 10:52:38 +0200 Subject: [PATCH 1/4] Generate new migration code and snapshot notebooks --- .../CFInterpolation.ipynb | 76 ++ .../CFInterpolationSnapshot.ipynb | 1087 +++++++++++++++++ 2 files changed, 1163 insertions(+) create mode 100644 ifrs17-template/Database/MigrationAndScaffolding/CFInterpolation.ipynb create mode 100644 ifrs17-template/Database/MigrationAndScaffolding/CFInterpolationSnapshot.ipynb diff --git a/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolation.ipynb b/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolation.ipynb new file mode 100644 index 00000000..dcc918b2 --- /dev/null +++ b/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolation.ipynb @@ -0,0 +1,76 @@ +{ + "metadata": { + "authors": [], + "id": "_miy4m8XeUyiykDsXoQrcA", + "kernelspec": { + "display_name": "Formula Framework", + "language": "C#", + "name": "C#" + }, + "language_info": { + "file_extension": ".cs", + "mimetype": "text/plain", + "name": "C#" + } + }, + "nbformat": 4, + "nbformat_minor": 5, + "cells": [ + { + "cell_type": "markdown", + "source": [ + "

Cashflow Interpolation Migration Code

" + ], + "metadata": {}, + "execution_count": 0, + "outputs": [] + }, + { + "cell_type": "markdown", + "source": [ + "This copy contains the copy of the cashflow interpolation migration code. It is a necessary input to execute the second migration flow. " + ], + "metadata": {}, + "execution_count": 0, + "outputs": [] + }, + { + "cell_type": "code", + "source": [ + "[Migration(\"20230412081831_CFInterpolationTypes\")]", + "\npublic class CFInterpolationTypes : Migration", + "\n{", + "\n protected override void Up(MigrationBuilder migrationBuilder)", + "\n {", + "\n migrationBuilder.AddColumn(", + "\n name: \"CashFlowPeriodicity\",", + "\n table: \"DataNodeParameter\",", + "\n type: \"int\",", + "\n nullable: true);", + "\n", + "\n migrationBuilder.AddColumn(", + "\n name: \"InterpolationMethod\",", + "\n table: \"DataNodeParameter\",", + "\n type: \"int\",", + "\n nullable: true);", + "\n }", + "\n", + "\n protected override void Down(MigrationBuilder migrationBuilder)", + "\n {", + "\n migrationBuilder.DropColumn(", + "\n name: \"CashFlowPeriodicity\",", + "\n table: \"DataNodeParameter\");", + "\n", + "\n migrationBuilder.DropColumn(", + "\n name: \"InterpolationMethod\",", + "\n table: \"DataNodeParameter\");", + "\n }", + "\n}", + "\n" + ], + "metadata": {}, + "execution_count": 0, + "outputs": [] + } + ] +} \ No newline at end of file diff --git a/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolationSnapshot.ipynb b/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolationSnapshot.ipynb new file mode 100644 index 00000000..c2555c25 --- /dev/null +++ b/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolationSnapshot.ipynb @@ -0,0 +1,1087 @@ +{ + "metadata": { + "authors": [], + "id": "vNiPiK2zNUuy5R4fqGNRQA", + "kernelspec": { + "display_name": "Formula Framework", + "language": "C#", + "name": "C#" + }, + "language_info": { + "file_extension": ".cs", + "mimetype": "text/plain", + "name": "C#" + } + }, + "nbformat": 4, + "nbformat_minor": 5, + "cells": [ + { + "cell_type": "markdown", + "source": [ + "

The Current Snapshot

" + ], + "metadata": {}, + "execution_count": 0, + "outputs": [] + }, + { + "cell_type": "markdown", + "source": [ + "Each time you produce a new migration, please copy and paste the snapshot code directly here. This must be the copy of the *most recent* migration snapshot. " + ], + "metadata": {}, + "execution_count": 0, + "outputs": [] + }, + { + "cell_type": "code", + "source": [ + "using Microsoft.EntityFrameworkCore;", + "\nusing Microsoft.EntityFrameworkCore.Infrastructure;", + "\nusing Microsoft.EntityFrameworkCore.Metadata;", + "\n", + "\npublic class DbModelSnapshot : ModelSnapshot", + "\n{", + "\n protected override void BuildModel(ModelBuilder modelBuilder)", + "\n {", + "\n modelBuilder", + "\n .HasAnnotation(\"ProductVersion\", \"6.0.1\")", + "\n .HasAnnotation(\"Relational:MaxIdentifierLength\", 128);", + "\n", + "\n SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1);", + "\n", + "\n modelBuilder.Entity(\"Submission_102+RawVariable\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"AccidentYear\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"AmountType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"AocType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"DataNode\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"EstimateType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Novelty\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Partition\")", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Values\")", + "\n .HasColumnType(\"varbinary(max)\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"RawVariable\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_103+IfrsVariable\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"AccidentYear\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"AmountType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"AocType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"DataNode\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"EconomicBasis\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"EstimateType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Novelty\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Partition\")", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Value\")", + "\n .HasColumnType(\"float\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"IfrsVariable\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_154+ImportExportActivity\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Category\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"EndDateTime\")", + "\n .HasColumnType(\"datetime2\");", + "\n", + "\n b.Property(\"ErrorMessages\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"ExceptionMessage\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"InfoMessages\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"SourceId\")", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"StartDateTime\")", + "\n .HasColumnType(\"datetime2\");", + "\n", + "\n b.Property(\"Status\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Username\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"WarningMessages\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"ImportExportActivity\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_156+ExportFile\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"ContentType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"CreationTime\")", + "\n .HasColumnType(\"datetime2\");", + "\n", + "\n b.Property(\"Format\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Length\")", + "\n .HasColumnType(\"bigint\");", + "\n", + "\n b.Property(\"Name\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"SerializedContent\")", + "\n .HasColumnType(\"varbinary(max)\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"ExportFile\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_158+ImportFile\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"ContentType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"CreationTime\")", + "\n .HasColumnType(\"datetime2\");", + "\n", + "\n b.Property(\"Directory\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Format\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Length\")", + "\n .HasColumnType(\"bigint\");", + "\n", + "\n b.Property(\"Name\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Partition\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"SerializedContent\")", + "\n .HasColumnType(\"varbinary(max)\");", + "\n", + "\n b.Property(\"Source\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"ImportFile\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_159+ImportString\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Content\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"CreationTime\")", + "\n .HasColumnType(\"datetime2\");", + "\n", + "\n b.Property(\"Format\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Length\")", + "\n .HasColumnType(\"bigint\");", + "\n", + "\n b.Property(\"SerializedContent\")", + "\n .HasColumnType(\"varbinary(max)\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"ImportString\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_160+ImportDataSet\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"CreationTime\")", + "\n .HasColumnType(\"datetime2\");", + "\n", + "\n b.Property(\"Format\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Length\")", + "\n .HasColumnType(\"bigint\");", + "\n", + "\n b.Property(\"SerializedContent\")", + "\n .HasColumnType(\"varbinary(max)\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"ImportDataSet\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_161+ImportStream\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"CreationTime\")", + "\n .HasColumnType(\"datetime2\");", + "\n", + "\n b.Property(\"Format\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Length\")", + "\n .HasColumnType(\"bigint\");", + "\n", + "\n b.Property(\"SerializedContent\")", + "\n .HasColumnType(\"varbinary(max)\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"ImportStream\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_174+YieldCurveReport\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Currency\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Index\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Month\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Scenario\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Value\")", + "\n .HasColumnType(\"float\");", + "\n", + "\n b.Property(\"Year\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"YieldCurveReport\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_61+AmountType\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"Discriminator\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"ExternalId\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Order\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Parent\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"PeriodType\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"AmountType\");", + "\n", + "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"AmountType\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_63+RiskDriver\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Order\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Parent\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"RiskDriver\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_64+EstimateType\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"ExternalId\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"InputSource\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Order\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"PeriodType\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"StructureType\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"EstimateType\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_65+Novelty\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Order\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"Novelty\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_66+VariableType\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"Discriminator\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Order\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Parent\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"VariableType\");", + "\n", + "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"VariableType\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_72+Scenario\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"Scenario\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_73+LineOfBusiness\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Order\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Parent\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"LineOfBusiness\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_74+Currency\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"Currency\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_75+EconomicBasis\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"EconomicBasis\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_76+ValuationApproach\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"ValuationApproach\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_77+LiabilityType\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Parent\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"LiabilityType\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_78+OciType\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"OciType\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_79+Profitability\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"Profitability\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_80+Partner\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"Partner\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_81+CreditRiskRating\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"CreditRiskRating\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_82+ReportingNode\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"Currency\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Parent\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"ReportingNode\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_83+ProjectionConfiguration\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Shift\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"TimeStep\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"ProjectionConfiguration\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_84+AocConfiguration\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"AocType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"CdrPeriod\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"DataType\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"FxPeriod\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"InputSource\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Month\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Novelty\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Order\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"RcPeriod\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"ValuationPeriod\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"YcPeriod\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Year\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"AocConfiguration\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_85+ExchangeRate\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Currency\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"FxToGroupCurrency\")", + "\n .HasColumnType(\"float\");", + "\n", + "\n b.Property(\"FxType\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Month\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Scenario\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Year\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"ExchangeRate\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_86+CreditDefaultRate\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"CreditRiskRating\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Month\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Scenario\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Values\")", + "\n .HasColumnType(\"varbinary(max)\");", + "\n", + "\n b.Property(\"Year\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"CreditDefaultRate\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_87+YieldCurve\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Currency\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Month\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Name\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Scenario\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Values\")", + "\n .HasColumnType(\"varbinary(max)\");", + "\n", + "\n b.Property(\"Year\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"YieldCurve\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_88+PartnerRating\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"CreditRiskRating\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Month\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Partner\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Scenario\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Year\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"PartnerRating\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_90+PartitionByReportingNode\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"ReportingNode\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"PartitionByReportingNode\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_91+PartitionByReportingNodeAndPeriod\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Month\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"ReportingNode\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Scenario\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Year\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"PartitionByReportingNodeAndPeriod\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_92+DataNode\", b =>", + "\n {", + "\n b.Property(\"SystemName\")", + "\n .HasMaxLength(16)", + "\n .HasColumnType(\"nvarchar(16)\");", + "\n", + "\n b.Property(\"ContractualCurrency\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Discriminator\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"DisplayName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"FunctionalCurrency\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"LineOfBusiness\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"OciType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Partition\")", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"ValuationApproach\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasKey(\"SystemName\");", + "\n", + "\n b.ToTable(\"DataNode\");", + "\n", + "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"DataNode\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_96+DataNodeState\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"DataNode\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Month\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Partition\")", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Scenario\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"State\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Year\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"DataNodeState\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_97+DataNodeParameter\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"DataNode\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Discriminator\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Month\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Partition\")", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Scenario\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Year\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"DataNodeParameter\");", + "\n", + "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"DataNodeParameter\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_62+DeferrableAmountType\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_61+AmountType\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"DeferrableAmountType\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_67+AocType\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_66+VariableType\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"AocType\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_69+PnlVariableType\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_66+VariableType\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"PnlVariableType\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_70+BsVariableType\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_66+VariableType\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"BsVariableType\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_71+AccountingVariableType\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_66+VariableType\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"AccountingVariableType\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_93+Portfolio\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_92+DataNode\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"Portfolio\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_94+GroupOfContract\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_92+DataNode\");", + "\n", + "\n b.Property(\"AnnualCohort\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"LiabilityType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Partner\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Portfolio\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Profitability\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"YieldCurveName\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"GroupOfContract\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_98+InterDataNodeParameter\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_97+DataNodeParameter\");", + "\n", + "\n b.Property(\"LinkedDataNode\")", + "\n .IsRequired()", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"ReinsuranceCoverage\")", + "\n .HasColumnType(\"float\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"InterDataNodeParameter\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_98+SingleDataNodeParameter\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_97+DataNodeParameter\");", + "\n", + "\n b.Property(\"CashFlowPeriodicity\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"InterpolationMethod\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"PremiumAllocation\")", + "\n .HasColumnType(\"float\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"SingleDataNodeParameter\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_93+InsurancePortfolio\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_93+Portfolio\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"InsurancePortfolio\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_93+ReinsurancePortfolio\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_93+Portfolio\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"ReinsurancePortfolio\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_95+GroupOfInsuranceContract\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_94+GroupOfContract\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"GroupOfInsuranceContract\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_95+GroupOfReinsuranceContract\", b =>", + "\n {", + "\n b.HasBaseType(\"Submission_94+GroupOfContract\");", + "\n", + "\n b.HasDiscriminator().HasValue(\"GroupOfReinsuranceContract\");", + "\n });", + "\n }", + "\n}", + "\n" + ], + "metadata": {}, + "execution_count": 0, + "outputs": [] + } + ] +} \ No newline at end of file From 2f4e113a887102374a01600ba2fbbf89ea3bea44 Mon Sep 17 00:00:00 2001 From: nnikolopoulos Date: Wed, 12 Apr 2023 10:53:07 +0200 Subject: [PATCH 2/4] Apply new types in MigrationFlow notebook --- .../Database/MigrationAndScaffolding/MigrationFlow.ipynb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ifrs17-template/Database/MigrationAndScaffolding/MigrationFlow.ipynb b/ifrs17-template/Database/MigrationAndScaffolding/MigrationFlow.ipynb index 9e2d964b..dfdee99f 100644 --- a/ifrs17-template/Database/MigrationAndScaffolding/MigrationFlow.ipynb +++ b/ifrs17-template/Database/MigrationAndScaffolding/MigrationFlow.ipynb @@ -47,7 +47,7 @@ { "cell_type": "code", "source": [ - "#!import \"Initial\"" + "#!import \"CFInterpolation\"" ], "metadata": {}, "execution_count": 0, @@ -66,7 +66,7 @@ "cell_type": "code", "source": [ "await SchemaMigrations", - "\n .Apply() // Change the class in <> for future migrations", + "\n .Apply() // Change the class in <> for future migrations", "\n .ToMsSql(connectionStringMsSql)", "\n .MigrateAsync();" ], From bb3bc64925e284fcf593bb1a7fc19502bbb61d58 Mon Sep 17 00:00:00 2001 From: nnikolopoulos Date: Wed, 12 Apr 2023 18:24:49 +0200 Subject: [PATCH 3/4] Implement feedback --- .../MigrationAndScaffolding/Initial.ipynb | 6 +- .../MigrationFlow.ipynb | 4 +- .../MigrationAndScaffolding/Snapshot.ipynb | 290 +++++++++--------- 3 files changed, 154 insertions(+), 146 deletions(-) diff --git a/ifrs17-template/Database/MigrationAndScaffolding/Initial.ipynb b/ifrs17-template/Database/MigrationAndScaffolding/Initial.ipynb index 2a022334..312469a8 100644 --- a/ifrs17-template/Database/MigrationAndScaffolding/Initial.ipynb +++ b/ifrs17-template/Database/MigrationAndScaffolding/Initial.ipynb @@ -37,7 +37,7 @@ { "cell_type": "code", "source": [ - "[Migration(\"20230208105811_InitialTypes\")]", + "[Migration(\"20230412161547_InitialTypes\")]", "\npublic class InitialTypes : Migration", "\n{", "\n protected override void Up(MigrationBuilder migrationBuilder)", @@ -160,7 +160,9 @@ "\n Discriminator = table.Column(type: \"nvarchar(max)\", nullable: false),", "\n LinkedDataNode = table.Column(type: \"nvarchar(max)\", nullable: true),", "\n ReinsuranceCoverage = table.Column(type: \"float\", nullable: true),", - "\n PremiumAllocation = table.Column(type: \"float\", nullable: true)", + "\n PremiumAllocation = table.Column(type: \"float\", nullable: true),", + "\n CashFlowPeriodicity = table.Column(type: \"int\", nullable: true),", + "\n InterpolationMethod = table.Column(type: \"int\", nullable: true)", "\n },", "\n constraints: table =>", "\n {", diff --git a/ifrs17-template/Database/MigrationAndScaffolding/MigrationFlow.ipynb b/ifrs17-template/Database/MigrationAndScaffolding/MigrationFlow.ipynb index dfdee99f..9e2d964b 100644 --- a/ifrs17-template/Database/MigrationAndScaffolding/MigrationFlow.ipynb +++ b/ifrs17-template/Database/MigrationAndScaffolding/MigrationFlow.ipynb @@ -47,7 +47,7 @@ { "cell_type": "code", "source": [ - "#!import \"CFInterpolation\"" + "#!import \"Initial\"" ], "metadata": {}, "execution_count": 0, @@ -66,7 +66,7 @@ "cell_type": "code", "source": [ "await SchemaMigrations", - "\n .Apply() // Change the class in <> for future migrations", + "\n .Apply() // Change the class in <> for future migrations", "\n .ToMsSql(connectionStringMsSql)", "\n .MigrateAsync();" ], diff --git a/ifrs17-template/Database/MigrationAndScaffolding/Snapshot.ipynb b/ifrs17-template/Database/MigrationAndScaffolding/Snapshot.ipynb index f0885c57..08182bd2 100644 --- a/ifrs17-template/Database/MigrationAndScaffolding/Snapshot.ipynb +++ b/ifrs17-template/Database/MigrationAndScaffolding/Snapshot.ipynb @@ -51,36 +51,80 @@ "\n", "\n SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1);", "\n", - "\n modelBuilder.Entity(\"Submission_151+YieldCurveReport\", b =>", + "\n modelBuilder.Entity(\"Submission_102+RawVariable\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", "\n .HasColumnType(\"uniqueidentifier\");", "\n", - "\n b.Property(\"Currency\")", + "\n b.Property(\"AccidentYear\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"AmountType\")", "\n .HasColumnType(\"nvarchar(max)\");", "\n", - "\n b.Property(\"Index\")", - "\n .HasColumnType(\"int\");", + "\n b.Property(\"AocType\")", + "\n .HasColumnType(\"nvarchar(max)\");", "\n", - "\n b.Property(\"Month\")", + "\n b.Property(\"DataNode\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"EstimateType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Novelty\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Partition\")", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Values\")", + "\n .HasColumnType(\"varbinary(max)\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"RawVariable\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_103+IfrsVariable\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"AccidentYear\")", "\n .HasColumnType(\"int\");", "\n", - "\n b.Property(\"Scenario\")", + "\n b.Property(\"AmountType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"AocType\")", "\n .HasColumnType(\"nvarchar(max)\");", "\n", + "\n b.Property(\"DataNode\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"EconomicBasis\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"EstimateType\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Novelty\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Partition\")", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", "\n b.Property(\"Value\")", "\n .HasColumnType(\"float\");", "\n", - "\n b.Property(\"Year\")", - "\n .HasColumnType(\"int\");", - "\n", "\n b.HasKey(\"Id\");", "\n", - "\n b.ToTable(\"YieldCurveReport\");", + "\n b.ToTable(\"IfrsVariable\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_287+ImportExportActivity\", b =>", + "\n modelBuilder.Entity(\"Submission_154+ImportExportActivity\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -121,7 +165,7 @@ "\n b.ToTable(\"ImportExportActivity\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_289+ExportFile\", b =>", + "\n modelBuilder.Entity(\"Submission_156+ExportFile\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -150,7 +194,7 @@ "\n b.ToTable(\"ExportFile\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_291+ImportFile\", b =>", + "\n modelBuilder.Entity(\"Submission_158+ImportFile\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -188,7 +232,7 @@ "\n b.ToTable(\"ImportFile\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_292+ImportString\", b =>", + "\n modelBuilder.Entity(\"Submission_159+ImportString\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -214,7 +258,7 @@ "\n b.ToTable(\"ImportString\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_293+ImportDataSet\", b =>", + "\n modelBuilder.Entity(\"Submission_160+ImportDataSet\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -237,7 +281,7 @@ "\n b.ToTable(\"ImportDataSet\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_294+ImportStream\", b =>", + "\n modelBuilder.Entity(\"Submission_161+ImportStream\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -260,7 +304,36 @@ "\n b.ToTable(\"ImportStream\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_57+AmountType\", b =>", + "\n modelBuilder.Entity(\"Submission_174+YieldCurveReport\", b =>", + "\n {", + "\n b.Property(\"Id\")", + "\n .ValueGeneratedOnAdd()", + "\n .HasColumnType(\"uniqueidentifier\");", + "\n", + "\n b.Property(\"Currency\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Index\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Month\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"Scenario\")", + "\n .HasColumnType(\"nvarchar(max)\");", + "\n", + "\n b.Property(\"Value\")", + "\n .HasColumnType(\"float\");", + "\n", + "\n b.Property(\"Year\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.HasKey(\"Id\");", + "\n", + "\n b.ToTable(\"YieldCurveReport\");", + "\n });", + "\n", + "\n modelBuilder.Entity(\"Submission_61+AmountType\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -292,7 +365,7 @@ "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"AmountType\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_59+RiskDriver\", b =>", + "\n modelBuilder.Entity(\"Submission_63+RiskDriver\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -312,7 +385,7 @@ "\n b.ToTable(\"RiskDriver\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_60+EstimateType\", b =>", + "\n modelBuilder.Entity(\"Submission_64+EstimateType\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -341,7 +414,7 @@ "\n b.ToTable(\"EstimateType\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_61+Novelty\", b =>", + "\n modelBuilder.Entity(\"Submission_65+Novelty\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -358,7 +431,7 @@ "\n b.ToTable(\"Novelty\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_62+VariableType\", b =>", + "\n modelBuilder.Entity(\"Submission_66+VariableType\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -384,7 +457,7 @@ "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"VariableType\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_68+Scenario\", b =>", + "\n modelBuilder.Entity(\"Submission_72+Scenario\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -398,7 +471,7 @@ "\n b.ToTable(\"Scenario\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_69+LineOfBusiness\", b =>", + "\n modelBuilder.Entity(\"Submission_73+LineOfBusiness\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -418,7 +491,7 @@ "\n b.ToTable(\"LineOfBusiness\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_70+Currency\", b =>", + "\n modelBuilder.Entity(\"Submission_74+Currency\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -432,7 +505,7 @@ "\n b.ToTable(\"Currency\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_71+EconomicBasis\", b =>", + "\n modelBuilder.Entity(\"Submission_75+EconomicBasis\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -446,7 +519,7 @@ "\n b.ToTable(\"EconomicBasis\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_72+ValuationApproach\", b =>", + "\n modelBuilder.Entity(\"Submission_76+ValuationApproach\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -460,7 +533,7 @@ "\n b.ToTable(\"ValuationApproach\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_73+LiabilityType\", b =>", + "\n modelBuilder.Entity(\"Submission_77+LiabilityType\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -477,7 +550,7 @@ "\n b.ToTable(\"LiabilityType\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_74+OciType\", b =>", + "\n modelBuilder.Entity(\"Submission_78+OciType\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -491,7 +564,7 @@ "\n b.ToTable(\"OciType\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_75+Profitability\", b =>", + "\n modelBuilder.Entity(\"Submission_79+Profitability\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -505,7 +578,7 @@ "\n b.ToTable(\"Profitability\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_76+Partner\", b =>", + "\n modelBuilder.Entity(\"Submission_80+Partner\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -519,7 +592,7 @@ "\n b.ToTable(\"Partner\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_77+CreditRiskRating\", b =>", + "\n modelBuilder.Entity(\"Submission_81+CreditRiskRating\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -533,7 +606,7 @@ "\n b.ToTable(\"CreditRiskRating\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_78+ReportingNode\", b =>", + "\n modelBuilder.Entity(\"Submission_82+ReportingNode\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -554,7 +627,7 @@ "\n b.ToTable(\"ReportingNode\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_79+ProjectionConfiguration\", b =>", + "\n modelBuilder.Entity(\"Submission_83+ProjectionConfiguration\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -574,7 +647,7 @@ "\n b.ToTable(\"ProjectionConfiguration\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_80+AocConfiguration\", b =>", + "\n modelBuilder.Entity(\"Submission_84+AocConfiguration\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -621,7 +694,7 @@ "\n b.ToTable(\"AocConfiguration\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_81+ExchangeRate\", b =>", + "\n modelBuilder.Entity(\"Submission_85+ExchangeRate\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -651,7 +724,7 @@ "\n b.ToTable(\"ExchangeRate\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_82+CreditDefaultRate\", b =>", + "\n modelBuilder.Entity(\"Submission_86+CreditDefaultRate\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -678,7 +751,7 @@ "\n b.ToTable(\"CreditDefaultRate\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_83+YieldCurve\", b =>", + "\n modelBuilder.Entity(\"Submission_87+YieldCurve\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -708,7 +781,7 @@ "\n b.ToTable(\"YieldCurve\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_84+PartnerRating\", b =>", + "\n modelBuilder.Entity(\"Submission_88+PartnerRating\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -736,7 +809,7 @@ "\n b.ToTable(\"PartnerRating\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_86+PartitionByReportingNode\", b =>", + "\n modelBuilder.Entity(\"Submission_90+PartitionByReportingNode\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -751,7 +824,7 @@ "\n b.ToTable(\"PartitionByReportingNode\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_87+PartitionByReportingNodeAndPeriod\", b =>", + "\n modelBuilder.Entity(\"Submission_91+PartitionByReportingNodeAndPeriod\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -775,7 +848,7 @@ "\n b.ToTable(\"PartitionByReportingNodeAndPeriod\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_88+DataNode\", b =>", + "\n modelBuilder.Entity(\"Submission_92+DataNode\", b =>", "\n {", "\n b.Property(\"SystemName\")", "\n .HasMaxLength(16)", @@ -814,7 +887,7 @@ "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"DataNode\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_92+DataNodeState\", b =>", + "\n modelBuilder.Entity(\"Submission_96+DataNodeState\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -844,7 +917,7 @@ "\n b.ToTable(\"DataNodeState\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_93+DataNodeParameter\", b =>", + "\n modelBuilder.Entity(\"Submission_97+DataNodeParameter\", b =>", "\n {", "\n b.Property(\"Id\")", "\n .ValueGeneratedOnAdd()", @@ -877,124 +950,51 @@ "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"DataNodeParameter\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_98+RawVariable\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"AccidentYear\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"AmountType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"AocType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"DataNode\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"EstimateType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Novelty\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Partition\")", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Values\")", - "\n .HasColumnType(\"varbinary(max)\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"RawVariable\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_99+IfrsVariable\", b =>", + "\n modelBuilder.Entity(\"Submission_62+DeferrableAmountType\", b =>", "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"AccidentYear\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"AmountType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"AocType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"DataNode\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"EconomicBasis\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"EstimateType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Novelty\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Partition\")", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Value\")", - "\n .HasColumnType(\"float\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"IfrsVariable\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_58+DeferrableAmountType\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_57+AmountType\");", + "\n b.HasBaseType(\"Submission_61+AmountType\");", "\n", "\n b.HasDiscriminator().HasValue(\"DeferrableAmountType\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_63+AocType\", b =>", + "\n modelBuilder.Entity(\"Submission_67+AocType\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_62+VariableType\");", + "\n b.HasBaseType(\"Submission_66+VariableType\");", "\n", "\n b.HasDiscriminator().HasValue(\"AocType\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_65+PnlVariableType\", b =>", + "\n modelBuilder.Entity(\"Submission_69+PnlVariableType\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_62+VariableType\");", + "\n b.HasBaseType(\"Submission_66+VariableType\");", "\n", "\n b.HasDiscriminator().HasValue(\"PnlVariableType\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_66+BsVariableType\", b =>", + "\n modelBuilder.Entity(\"Submission_70+BsVariableType\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_62+VariableType\");", + "\n b.HasBaseType(\"Submission_66+VariableType\");", "\n", "\n b.HasDiscriminator().HasValue(\"BsVariableType\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_67+AccountingVariableType\", b =>", + "\n modelBuilder.Entity(\"Submission_71+AccountingVariableType\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_62+VariableType\");", + "\n b.HasBaseType(\"Submission_66+VariableType\");", "\n", "\n b.HasDiscriminator().HasValue(\"AccountingVariableType\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_89+Portfolio\", b =>", + "\n modelBuilder.Entity(\"Submission_93+Portfolio\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_88+DataNode\");", + "\n b.HasBaseType(\"Submission_92+DataNode\");", "\n", "\n b.HasDiscriminator().HasValue(\"Portfolio\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_90+GroupOfContract\", b =>", + "\n modelBuilder.Entity(\"Submission_94+GroupOfContract\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_88+DataNode\");", + "\n b.HasBaseType(\"Submission_92+DataNode\");", "\n", "\n b.Property(\"AnnualCohort\")", "\n .HasColumnType(\"int\");", @@ -1018,9 +1018,9 @@ "\n b.HasDiscriminator().HasValue(\"GroupOfContract\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_94+InterDataNodeParameter\", b =>", + "\n modelBuilder.Entity(\"Submission_98+InterDataNodeParameter\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_93+DataNodeParameter\");", + "\n b.HasBaseType(\"Submission_97+DataNodeParameter\");", "\n", "\n b.Property(\"LinkedDataNode\")", "\n .IsRequired()", @@ -1032,9 +1032,15 @@ "\n b.HasDiscriminator().HasValue(\"InterDataNodeParameter\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_94+SingleDataNodeParameter\", b =>", + "\n modelBuilder.Entity(\"Submission_98+SingleDataNodeParameter\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_93+DataNodeParameter\");", + "\n b.HasBaseType(\"Submission_97+DataNodeParameter\");", + "\n", + "\n b.Property(\"CashFlowPeriodicity\")", + "\n .HasColumnType(\"int\");", + "\n", + "\n b.Property(\"InterpolationMethod\")", + "\n .HasColumnType(\"int\");", "\n", "\n b.Property(\"PremiumAllocation\")", "\n .HasColumnType(\"float\");", @@ -1042,30 +1048,30 @@ "\n b.HasDiscriminator().HasValue(\"SingleDataNodeParameter\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_89+InsurancePortfolio\", b =>", + "\n modelBuilder.Entity(\"Submission_93+InsurancePortfolio\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_89+Portfolio\");", + "\n b.HasBaseType(\"Submission_93+Portfolio\");", "\n", "\n b.HasDiscriminator().HasValue(\"InsurancePortfolio\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_89+ReinsurancePortfolio\", b =>", + "\n modelBuilder.Entity(\"Submission_93+ReinsurancePortfolio\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_89+Portfolio\");", + "\n b.HasBaseType(\"Submission_93+Portfolio\");", "\n", "\n b.HasDiscriminator().HasValue(\"ReinsurancePortfolio\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_91+GroupOfInsuranceContract\", b =>", + "\n modelBuilder.Entity(\"Submission_95+GroupOfInsuranceContract\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_90+GroupOfContract\");", + "\n b.HasBaseType(\"Submission_94+GroupOfContract\");", "\n", "\n b.HasDiscriminator().HasValue(\"GroupOfInsuranceContract\");", "\n });", "\n", - "\n modelBuilder.Entity(\"Submission_91+GroupOfReinsuranceContract\", b =>", + "\n modelBuilder.Entity(\"Submission_95+GroupOfReinsuranceContract\", b =>", "\n {", - "\n b.HasBaseType(\"Submission_90+GroupOfContract\");", + "\n b.HasBaseType(\"Submission_94+GroupOfContract\");", "\n", "\n b.HasDiscriminator().HasValue(\"GroupOfReinsuranceContract\");", "\n });", From 2ba42c6640538d104c0afb72ee10b8afee1558f2 Mon Sep 17 00:00:00 2001 From: nnikolopoulos Date: Wed, 12 Apr 2023 18:43:01 +0200 Subject: [PATCH 4/4] Remove CFInterpolation and CFInterpolationSnapshot --- .../CFInterpolation.ipynb | 76 -- .../CFInterpolationSnapshot.ipynb | 1087 ----------------- 2 files changed, 1163 deletions(-) delete mode 100644 ifrs17-template/Database/MigrationAndScaffolding/CFInterpolation.ipynb delete mode 100644 ifrs17-template/Database/MigrationAndScaffolding/CFInterpolationSnapshot.ipynb diff --git a/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolation.ipynb b/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolation.ipynb deleted file mode 100644 index dcc918b2..00000000 --- a/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolation.ipynb +++ /dev/null @@ -1,76 +0,0 @@ -{ - "metadata": { - "authors": [], - "id": "_miy4m8XeUyiykDsXoQrcA", - "kernelspec": { - "display_name": "Formula Framework", - "language": "C#", - "name": "C#" - }, - "language_info": { - "file_extension": ".cs", - "mimetype": "text/plain", - "name": "C#" - } - }, - "nbformat": 4, - "nbformat_minor": 5, - "cells": [ - { - "cell_type": "markdown", - "source": [ - "

Cashflow Interpolation Migration Code

" - ], - "metadata": {}, - "execution_count": 0, - "outputs": [] - }, - { - "cell_type": "markdown", - "source": [ - "This copy contains the copy of the cashflow interpolation migration code. It is a necessary input to execute the second migration flow. " - ], - "metadata": {}, - "execution_count": 0, - "outputs": [] - }, - { - "cell_type": "code", - "source": [ - "[Migration(\"20230412081831_CFInterpolationTypes\")]", - "\npublic class CFInterpolationTypes : Migration", - "\n{", - "\n protected override void Up(MigrationBuilder migrationBuilder)", - "\n {", - "\n migrationBuilder.AddColumn(", - "\n name: \"CashFlowPeriodicity\",", - "\n table: \"DataNodeParameter\",", - "\n type: \"int\",", - "\n nullable: true);", - "\n", - "\n migrationBuilder.AddColumn(", - "\n name: \"InterpolationMethod\",", - "\n table: \"DataNodeParameter\",", - "\n type: \"int\",", - "\n nullable: true);", - "\n }", - "\n", - "\n protected override void Down(MigrationBuilder migrationBuilder)", - "\n {", - "\n migrationBuilder.DropColumn(", - "\n name: \"CashFlowPeriodicity\",", - "\n table: \"DataNodeParameter\");", - "\n", - "\n migrationBuilder.DropColumn(", - "\n name: \"InterpolationMethod\",", - "\n table: \"DataNodeParameter\");", - "\n }", - "\n}", - "\n" - ], - "metadata": {}, - "execution_count": 0, - "outputs": [] - } - ] -} \ No newline at end of file diff --git a/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolationSnapshot.ipynb b/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolationSnapshot.ipynb deleted file mode 100644 index c2555c25..00000000 --- a/ifrs17-template/Database/MigrationAndScaffolding/CFInterpolationSnapshot.ipynb +++ /dev/null @@ -1,1087 +0,0 @@ -{ - "metadata": { - "authors": [], - "id": "vNiPiK2zNUuy5R4fqGNRQA", - "kernelspec": { - "display_name": "Formula Framework", - "language": "C#", - "name": "C#" - }, - "language_info": { - "file_extension": ".cs", - "mimetype": "text/plain", - "name": "C#" - } - }, - "nbformat": 4, - "nbformat_minor": 5, - "cells": [ - { - "cell_type": "markdown", - "source": [ - "

The Current Snapshot

" - ], - "metadata": {}, - "execution_count": 0, - "outputs": [] - }, - { - "cell_type": "markdown", - "source": [ - "Each time you produce a new migration, please copy and paste the snapshot code directly here. This must be the copy of the *most recent* migration snapshot. " - ], - "metadata": {}, - "execution_count": 0, - "outputs": [] - }, - { - "cell_type": "code", - "source": [ - "using Microsoft.EntityFrameworkCore;", - "\nusing Microsoft.EntityFrameworkCore.Infrastructure;", - "\nusing Microsoft.EntityFrameworkCore.Metadata;", - "\n", - "\npublic class DbModelSnapshot : ModelSnapshot", - "\n{", - "\n protected override void BuildModel(ModelBuilder modelBuilder)", - "\n {", - "\n modelBuilder", - "\n .HasAnnotation(\"ProductVersion\", \"6.0.1\")", - "\n .HasAnnotation(\"Relational:MaxIdentifierLength\", 128);", - "\n", - "\n SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1);", - "\n", - "\n modelBuilder.Entity(\"Submission_102+RawVariable\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"AccidentYear\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"AmountType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"AocType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"DataNode\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"EstimateType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Novelty\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Partition\")", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Values\")", - "\n .HasColumnType(\"varbinary(max)\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"RawVariable\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_103+IfrsVariable\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"AccidentYear\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"AmountType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"AocType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"DataNode\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"EconomicBasis\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"EstimateType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Novelty\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Partition\")", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Value\")", - "\n .HasColumnType(\"float\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"IfrsVariable\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_154+ImportExportActivity\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Category\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"EndDateTime\")", - "\n .HasColumnType(\"datetime2\");", - "\n", - "\n b.Property(\"ErrorMessages\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"ExceptionMessage\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"InfoMessages\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"SourceId\")", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"StartDateTime\")", - "\n .HasColumnType(\"datetime2\");", - "\n", - "\n b.Property(\"Status\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Username\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"WarningMessages\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"ImportExportActivity\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_156+ExportFile\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"ContentType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"CreationTime\")", - "\n .HasColumnType(\"datetime2\");", - "\n", - "\n b.Property(\"Format\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Length\")", - "\n .HasColumnType(\"bigint\");", - "\n", - "\n b.Property(\"Name\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"SerializedContent\")", - "\n .HasColumnType(\"varbinary(max)\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"ExportFile\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_158+ImportFile\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"ContentType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"CreationTime\")", - "\n .HasColumnType(\"datetime2\");", - "\n", - "\n b.Property(\"Directory\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Format\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Length\")", - "\n .HasColumnType(\"bigint\");", - "\n", - "\n b.Property(\"Name\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Partition\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"SerializedContent\")", - "\n .HasColumnType(\"varbinary(max)\");", - "\n", - "\n b.Property(\"Source\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"ImportFile\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_159+ImportString\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Content\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"CreationTime\")", - "\n .HasColumnType(\"datetime2\");", - "\n", - "\n b.Property(\"Format\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Length\")", - "\n .HasColumnType(\"bigint\");", - "\n", - "\n b.Property(\"SerializedContent\")", - "\n .HasColumnType(\"varbinary(max)\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"ImportString\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_160+ImportDataSet\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"CreationTime\")", - "\n .HasColumnType(\"datetime2\");", - "\n", - "\n b.Property(\"Format\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Length\")", - "\n .HasColumnType(\"bigint\");", - "\n", - "\n b.Property(\"SerializedContent\")", - "\n .HasColumnType(\"varbinary(max)\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"ImportDataSet\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_161+ImportStream\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"CreationTime\")", - "\n .HasColumnType(\"datetime2\");", - "\n", - "\n b.Property(\"Format\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Length\")", - "\n .HasColumnType(\"bigint\");", - "\n", - "\n b.Property(\"SerializedContent\")", - "\n .HasColumnType(\"varbinary(max)\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"ImportStream\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_174+YieldCurveReport\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Currency\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Index\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Month\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Scenario\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Value\")", - "\n .HasColumnType(\"float\");", - "\n", - "\n b.Property(\"Year\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"YieldCurveReport\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_61+AmountType\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"Discriminator\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"ExternalId\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Order\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Parent\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"PeriodType\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"AmountType\");", - "\n", - "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"AmountType\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_63+RiskDriver\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Order\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Parent\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"RiskDriver\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_64+EstimateType\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"ExternalId\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"InputSource\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Order\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"PeriodType\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"StructureType\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"EstimateType\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_65+Novelty\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Order\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"Novelty\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_66+VariableType\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"Discriminator\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Order\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Parent\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"VariableType\");", - "\n", - "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"VariableType\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_72+Scenario\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"Scenario\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_73+LineOfBusiness\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Order\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Parent\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"LineOfBusiness\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_74+Currency\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"Currency\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_75+EconomicBasis\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"EconomicBasis\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_76+ValuationApproach\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"ValuationApproach\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_77+LiabilityType\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Parent\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"LiabilityType\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_78+OciType\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"OciType\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_79+Profitability\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"Profitability\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_80+Partner\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"Partner\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_81+CreditRiskRating\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"CreditRiskRating\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_82+ReportingNode\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"Currency\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Parent\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"ReportingNode\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_83+ProjectionConfiguration\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Shift\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"TimeStep\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"ProjectionConfiguration\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_84+AocConfiguration\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"AocType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"CdrPeriod\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"DataType\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"FxPeriod\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"InputSource\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Month\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Novelty\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Order\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"RcPeriod\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"ValuationPeriod\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"YcPeriod\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Year\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"AocConfiguration\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_85+ExchangeRate\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Currency\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"FxToGroupCurrency\")", - "\n .HasColumnType(\"float\");", - "\n", - "\n b.Property(\"FxType\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Month\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Scenario\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Year\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"ExchangeRate\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_86+CreditDefaultRate\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"CreditRiskRating\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Month\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Scenario\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Values\")", - "\n .HasColumnType(\"varbinary(max)\");", - "\n", - "\n b.Property(\"Year\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"CreditDefaultRate\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_87+YieldCurve\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Currency\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Month\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Name\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Scenario\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Values\")", - "\n .HasColumnType(\"varbinary(max)\");", - "\n", - "\n b.Property(\"Year\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"YieldCurve\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_88+PartnerRating\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"CreditRiskRating\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Month\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Partner\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Scenario\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Year\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"PartnerRating\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_90+PartitionByReportingNode\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"ReportingNode\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"PartitionByReportingNode\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_91+PartitionByReportingNodeAndPeriod\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Month\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"ReportingNode\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Scenario\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Year\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"PartitionByReportingNodeAndPeriod\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_92+DataNode\", b =>", - "\n {", - "\n b.Property(\"SystemName\")", - "\n .HasMaxLength(16)", - "\n .HasColumnType(\"nvarchar(16)\");", - "\n", - "\n b.Property(\"ContractualCurrency\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Discriminator\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"DisplayName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"FunctionalCurrency\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"LineOfBusiness\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"OciType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Partition\")", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"ValuationApproach\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasKey(\"SystemName\");", - "\n", - "\n b.ToTable(\"DataNode\");", - "\n", - "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"DataNode\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_96+DataNodeState\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"DataNode\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Month\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Partition\")", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Scenario\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"State\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Year\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"DataNodeState\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_97+DataNodeParameter\", b =>", - "\n {", - "\n b.Property(\"Id\")", - "\n .ValueGeneratedOnAdd()", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"DataNode\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Discriminator\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Month\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"Partition\")", - "\n .HasColumnType(\"uniqueidentifier\");", - "\n", - "\n b.Property(\"Scenario\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Year\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.HasKey(\"Id\");", - "\n", - "\n b.ToTable(\"DataNodeParameter\");", - "\n", - "\n b.HasDiscriminator(\"Discriminator\").HasValue(\"DataNodeParameter\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_62+DeferrableAmountType\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_61+AmountType\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"DeferrableAmountType\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_67+AocType\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_66+VariableType\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"AocType\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_69+PnlVariableType\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_66+VariableType\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"PnlVariableType\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_70+BsVariableType\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_66+VariableType\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"BsVariableType\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_71+AccountingVariableType\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_66+VariableType\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"AccountingVariableType\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_93+Portfolio\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_92+DataNode\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"Portfolio\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_94+GroupOfContract\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_92+DataNode\");", - "\n", - "\n b.Property(\"AnnualCohort\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"LiabilityType\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Partner\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Portfolio\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"Profitability\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"YieldCurveName\")", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"GroupOfContract\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_98+InterDataNodeParameter\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_97+DataNodeParameter\");", - "\n", - "\n b.Property(\"LinkedDataNode\")", - "\n .IsRequired()", - "\n .HasColumnType(\"nvarchar(max)\");", - "\n", - "\n b.Property(\"ReinsuranceCoverage\")", - "\n .HasColumnType(\"float\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"InterDataNodeParameter\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_98+SingleDataNodeParameter\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_97+DataNodeParameter\");", - "\n", - "\n b.Property(\"CashFlowPeriodicity\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"InterpolationMethod\")", - "\n .HasColumnType(\"int\");", - "\n", - "\n b.Property(\"PremiumAllocation\")", - "\n .HasColumnType(\"float\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"SingleDataNodeParameter\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_93+InsurancePortfolio\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_93+Portfolio\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"InsurancePortfolio\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_93+ReinsurancePortfolio\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_93+Portfolio\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"ReinsurancePortfolio\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_95+GroupOfInsuranceContract\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_94+GroupOfContract\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"GroupOfInsuranceContract\");", - "\n });", - "\n", - "\n modelBuilder.Entity(\"Submission_95+GroupOfReinsuranceContract\", b =>", - "\n {", - "\n b.HasBaseType(\"Submission_94+GroupOfContract\");", - "\n", - "\n b.HasDiscriminator().HasValue(\"GroupOfReinsuranceContract\");", - "\n });", - "\n }", - "\n}", - "\n" - ], - "metadata": {}, - "execution_count": 0, - "outputs": [] - } - ] -} \ No newline at end of file