Results 1 to 2 of 2
  1. #1
    Join Date
    Dec 2012

    Unanswered: Positioned update in Dynamic SQL cursor


    I have a situation where a table is being created in the procedure and therefore a dynamic cursor is defined over the table and a loop is defined to span through the records of this cursor.

    In the loop a piece of code generates two columns which are supposed to be updated in the table that was created above. It would be very simple if I can perform a positioned update using the dynamic cursor but I get an error when I declare the dynamic cursor as it does not recognise the columns mentioned in the 'FOR UPDATE OF' (as the table is being created using dynamic SQL statement)

    Is it possible to define a dynamic positioned update cursor using parameter markers (or some how) ?

  2. #2
    Join Date
    Jan 2003
    Provided Answers: 5
    Please post your DB2 version and OS. Can you post the code you have tried so far?


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts