Skip to content

Commit

Permalink
Merge pull request #56 from CEDStandards/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
aemnathanclinton committed Jul 11, 2022
2 parents 5132396 + ff87e48 commit efa6cf2
Show file tree
Hide file tree
Showing 4 changed files with 47 additions and 4 deletions.
Binary file modified src/ddl/CEDS-IDS.sql
Binary file not shown.
4 changes: 2 additions & 2 deletions src/metadata/Populate-CEDS-Element-Tables.sql
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@

*/

-- Uncomment next two lines to update a database named CEDS-IDS-V10_0_0_0 or specify appropriate DB name for your server.
--USE [CEDS-IDS-V10_0_0_0];
-- Uncomment next two lines to update a database named CEDS-IDS-V10_0_1_0 or specify appropriate DB name for your server.
--USE [CEDS-IDS-V10_0_1_0];
--GO


Expand Down
4 changes: 2 additions & 2 deletions src/reference-data/Populate-CEDS-Ref-Tables.sql
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@

*/

-- Uncomment next two lines to update a database named CEDS-IDS-V10_0_0_0 or specify appropriate DB name for your server.
--USE [CEDS-IDS-V10_0_0_0];
-- Uncomment next two lines to update a database named CEDS-IDS-V10_0_1_0 or specify appropriate DB name for your server.
--USE [CEDS-IDS-V10_0_1_0];
--GO

-- change @updateExisting to 1 to update all existing Ref table values matching Codes and for Ref tables that include a FK to other Ref tables (not RefJurisdictionId) matching Code and Description
Expand Down
43 changes: 43 additions & 0 deletions src/upgrade/V10-to-V10.0.1.0.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
/****** Object: Table [dbo].[OrganizationPersonRoleRelationship] Script Date: 5/26/2022 8:56:58 AM ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[OrganizationPersonRoleRelationship](
[OrganizationPersonRoleRelationshipId] [int] IDENTITY(1,1) NOT NULL,
[OrganizationPersonRoleId] [int] NOT NULL,
[OrganizationPersonRoleId_Parent] [int] NOT NULL,
[RecordStartDateTime] [datetime] NULL,
[RecordEndDateTime] [datetime] NULL,
[DataCollectionId] [int] NULL,
CONSTRAINT [PK_OrganizationPersonRoleRelationship] PRIMARY KEY CLUSTERED
(
[OrganizationPersonRoleRelationshipId] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY]
GO

ALTER TABLE [dbo].[OrganizationPersonRoleRelationship] WITH CHECK ADD CONSTRAINT [FK_OrganizationPersonRoleRelationship_DataCollection] FOREIGN KEY([DataCollectionId])
REFERENCES [dbo].[DataCollection] ([DataCollectionId])
GO

ALTER TABLE [dbo].[OrganizationPersonRoleRelationship] CHECK CONSTRAINT [FK_OrganizationPersonRoleRelationship_DataCollection]
GO

ALTER TABLE [dbo].[OrganizationPersonRoleRelationship] WITH CHECK ADD CONSTRAINT [FK_OrganizationPersonRoleRelationship_OrganizationPersonRole] FOREIGN KEY([OrganizationPersonRoleId])
REFERENCES [dbo].[OrganizationPersonRole] ([OrganizationPersonRoleId])
GO

ALTER TABLE [dbo].[OrganizationPersonRoleRelationship] CHECK CONSTRAINT [FK_OrganizationPersonRoleRelationship_OrganizationPersonRole]
GO

ALTER TABLE [dbo].[OrganizationPersonRoleRelationship] WITH CHECK ADD CONSTRAINT [FK_OrganizationPersonRoleRelationship_OrganizationPersonRole_Parent] FOREIGN KEY([OrganizationPersonRoleId_Parent])
REFERENCES [dbo].[OrganizationPersonRole] ([OrganizationPersonRoleId])
GO

ALTER TABLE [dbo].[OrganizationPersonRoleRelationship] CHECK CONSTRAINT [FK_OrganizationPersonRoleRelationship_OrganizationPersonRole_Parent]
GO


0 comments on commit efa6cf2

Please sign in to comment.