What is the value you are trying to compare SampledDate or FurnaceID?
Try using recursive CTE than chosing cursor for this operation.
http://msdn.microsoft.com/en-us/library/ms186243(v=sql.105).aspx
https://www.simple-talk.com/sql/t-sql-programming/sql-server-cte-basics/
Please use Marked as Answer if my post solved your problem and use Vote As Helpful if a post was useful.
No comments:
Post a Comment