How to alter sequence in db2 luw in porcedure

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • samuel ray
    New Member
    • Jul 2011
    • 4

    How to alter sequence in db2 luw in porcedure

    We are using DB2 LUW Version 10.5.0.5 on Linux (x86_64) We have written a procedure to alter a sequence to restart with a certain number. The procedure takes the sequence name and the number to restart with as parameters. The procedure got created successfully . We have granted developers connect access on the database and execute access on the procedure. But they are getting SQL -551 (permission issue for alter sequence sql) upon executing the procedure. Create sequence works perfectly fine when it is executed in a procedure by anyone who even doesn't have create sequence access. Is there a reason why the alter sequence command doesn't work in a procedure? Is there a way to allow developers to alter a sequence in a database without granting alter access on the sequence itself?
Working...