begin select @s_id,@name,@age,@counter fetch c_student into @s_id,@name,@age select @counter=@counter+1 . . end 这句好像不对吧 而且这段游标好像不在做什么事情 ----------------------- When you write code for a transaction that retrieves a single row of results, you can use a SELECT INTO statement. This is called a singleton SELECT statement.When you write code for a transaction where the result set includes several rows of data, you must declare and use a cursor. A cursor is a mechanism you can use to fetch rows one at a time...
select @s_id,@name,@age,@counter
fetch c_student into @s_id,@name,@age
select @counter=@counter+1
.
.
end
这句好像不对吧
而且这段游标好像不在做什么事情
-----------------------
When you write code for a transaction that retrieves a single row of results, you can use a SELECT INTO statement. This is called a singleton SELECT statement.When you write code for a transaction where the result set includes several rows of data, you must declare and use a cursor. A cursor is a mechanism you can use to fetch rows one at a time...
那游标的这个性能有点象 ADO.NET 中的DataRow 对象的功能,也就是说单从功能上讲DataRow是不是可以代替游标??