This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

SQL Return code = 1054 getting on open cursor

  • 1. I am facing 1054 return code on below cursor while opening the cursor on MySql8 through Visual COBOL 6.

    2. Below cursor is working fine on Mysql5 through server express

    3. Same cursor is running fine in stored proc created on mySql8

    4. Project requires row level lock while fetching the cursor.

    5. Can you please suggest how to make running this cursor on MySql8 through Visual COBOL6.0 with lock on row.

    6.If we comment "for update" lock on Visual COBOL 6, it works fine but it is not satisfying project requirement.

    Cursore :

    exec sql   declare my_cursor cursor for select  date_format (cstrc_date, '%Y%m%d), cstrc_number from cstrctrl where owing_location=:ws-branch order by cstrc_date,cstrc_number for update

Parents
  • What patch update level do you have applied to Visual COBOL 6.0 and what is the exact version of MySQL 8.0 Server/Client you are using?

    You should test with the latest available which is patch update 17 as we did not test against MySQL 8.0 with earlier releases.

    If patch update 17 does not fix the problem then I would recommend opening up a support incident with Customer Care so that we can investigate this further.

    Chris Glazier
    Global Technical Support | OpenText


    If you found this post useful, give it a “Like” or click on "
    Verify Answer" under the "More" button

  • One more thing you might try if you do not require positioned updates is to try the directive NOWHERECURRENT.

    Please see the documentation here:

    Chris Glazier
    Global Technical Support | OpenText


    If you found this post useful, give it a “Like” or click on "
    Verify Answer" under the "More" button

Reply Children
No Data