CREATE TABLE [dbo].[pol_policies_situations_regul_invoices]
(
[polsri_policy_situation_id] [int] NOT NULL,
[polsri_invoice_id] [int] NOT NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[pol_policies_situations_regul_invoices] ADD CONSTRAINT [PK_pol_policies_situations_regul_invoices] PRIMARY KEY CLUSTERED  ([polsri_policy_situation_id], [polsri_invoice_id]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[pol_policies_situations_regul_invoices] ADD CONSTRAINT [FK_pol_policies_situations_regul_invoices_acc_invoices] FOREIGN KEY ([polsri_invoice_id]) REFERENCES [dbo].[acc_invoices] ([inv_invoice_id])
GO
ALTER TABLE [dbo].[pol_policies_situations_regul_invoices] ADD CONSTRAINT [FK_pol_policies_situations_regul_invoices_pol_policies_situations] FOREIGN KEY ([polsri_policy_situation_id]) REFERENCES [dbo].[pol_policies_situations] ([pols_policy_situation_id])
GO
