摘要:
如果游标是可更新的(也就是说,在定义游标语句中不包括Read Only 参数),就可以用游标从游标数据的源表中DELETE/UPDATE行,即DELETE/UPDATE基于游标指针的当前位置的操作;举例:--删除当前行的记录Declare cur_Depart CursorFor Select cDeptID,cDeptName From Department into @DeptID,@DeptNameOpen cur_DepartFetch From cur_Depart into @DeptID,@DeptNameDelete From Department Where CURRENT 阅读全文