• I would love to use it, but I'm getting the following error messages:

    Msg 16916, Level 16, State 1, Procedure GenerateInsertStatement, Line 70

    A cursor with the name 'rec_col' does not exist.

    Msg 16916, Level 16, State 1, Procedure GenerateInsertStatement, Line 72

    A cursor with the name 'rec_col' does not exist.

    Msg 16916, Level 16, State 1, Procedure GenerateInsertStatement, Line 126

    A cursor with the name 'rec_col' does not exist.

    Msg 16916, Level 16, State 1, Procedure GenerateInsertStatement, Line 127

    A cursor with the name 'rec_col' does not exist.

    I see where the cursor is being created, but not sure why it's not working.