SET QUOTED_IDENTIFIER ON
GO
SET ANSI_NULLS ON
GO
create procedure [dbo].[p_test_claims_delete]
as

	declare c_claims insensitive cursor 
	for	select	cl_claim_id
		from	claim_claims

	declare @claim_id int

	open c_claims

	fetch next from c_claims into @claim_id

	while @@FETCH_STATUS = 0 
	begin
		exec p_test_claim_delete_by_id @claim_id

		fetch next from c_claims into @claim_id
	end

	close c_claims
	deallocate c_claims
GO
