ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

Locks when creating a SQL View

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Locks when creating a SQL View

    I need to write a program which creates a complex SQL view. However when I do it by RPG embedded SQL or use the RUNSQL command it locks the view (see picture).

    I need to change the view description and owner on the fly which I can't because the file (view) is locked.

    How can I create the view without locking it? Or how can I release the lock?


    Thank you


  • #2
    I just solved it. Commit must be set to none.

    Code:
    /free                                                 
     exec sql                                             
       set option commit=*none;        
    /end-free

    Comment

    Working...
    X