CREATE TABLE [dbo].[claim_variables]
(
[clv_claim_id] [int] NOT NULL,
[clv_variable_id] [int] NOT NULL,
[clv_company_id] [int] NOT NULL,
[clv_provision] [dbo].[ais_decimal2] NULL,
[clv_provision_repr] [dbo].[ais_decimal2] NULL,
[clv_recovery] [dbo].[ais_decimal2] NULL,
[clv_payment] [dbo].[ais_decimal2] NULL,
[clv_received_recovery] [dbo].[ais_decimal2] NULL,
[clv_provision_injury] [dbo].[ais_decimal2] NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[claim_variables] ADD CONSTRAINT [PK_claim_variables] PRIMARY KEY CLUSTERED  ([clv_claim_id], [clv_variable_id]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[claim_variables] ADD CONSTRAINT [FK_claim_variables_act_cies] FOREIGN KEY ([clv_company_id]) REFERENCES [dbo].[act_cies] ([cie_actor_id])
GO
ALTER TABLE [dbo].[claim_variables] ADD CONSTRAINT [FK_claim_variables_claim_claims] FOREIGN KEY ([clv_claim_id]) REFERENCES [dbo].[claim_claims] ([cl_claim_id])
GO
