SET NOCOUNT ON; SET QUOTED_IDENTIFIER ON; DECLARE @Quoteid VARCHAR(50) DECLARE db_cursor CURSOR FOR Select QuoteID from quote with (nolock) where LOB=''claim'' and Deleted<>1 and QuoteID not in (select QuoteID from claimsdata) OPEN db_cursor FETCH NEXT FROM db_cursor INTO @Quoteid WHILE @@FETCH_STATUS = 0 BEGIN INSERT INTO ClaimsData SELECT * FROM Quote with (nolock) Where QuoteID=@Quoteid; FETCH NEXT FROM db_cursor INTO @Quoteid END CLOSE db_cursor DEALLOCATE db_cursor
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)