DECLARE cursor1 CURSOR
FOR select field1,field2,... from table1
OPEN cursor1
FETCH NEXT from cursor1 into @field1,@field2,...
WHILE @@FETCH_STATUS = 0
BEGIN
دستورات مورد نظر
FETCH NEXT FROM cursor1 INTO @field1,@field2,...
end
CLOSE cursor1
DEALLOCATE cursor1