Can I get the results of a stored procedure into a cursor within another stored procedure in SQL

前端 未结 3 1548
慢半拍i
慢半拍i 2021-01-11 15:36

I\'m trying to put the results of a stored procedure into a cursor to use within the current procedure. I\'ve added my code below but I\'m not sure if this is possible or if

3条回答
  •  梦毁少年i
    2021-01-11 15:51

    The syntax of cursor in SQL-Server is:

    DECLARE cursor_name [ INSENSITIVE ] [ SCROLL ] CURSOR FOR select_statement   
    

    After FOR you must write a SELECT.

    For more info see: https://msdn.microsoft.com/it-it/library/ms180169.aspx

提交回复
热议问题