Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!
declare @RecordID int, @Price int declare csr cursor for Select top 100 a.RecordID FROM Records ORDER BY a.RecordDate desc open csr fetch next from csr into @RecordID while @@FETCH_STATUS = 0 begin --cursor loop set @Price = (SELECT Price FROM Records where RecordID = @RecordID) if @Price > 0 begin update Records set Priced = 1 where RecordID = @RecordID end else begin update Records set Priced = 0 where RecordID = @RecordID end fetch next from csr into @RecordID end --cursor loop close csr deallocate csr
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.