IX lock not released

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

    IX lock not released

    i am using type 4 driver with fp3 on windows 64bit server, auto commit
    is true, cursor is CS type.

    i have a sensitive , updatable cursor open and bring back a one row
    resultset, i get this locklist

    Lock Name = 0x020027011C000 0000000000052
    Lock Attributes = 0x00000000
    Release Flags = 0x00000002
    Lock Count = 1
    Hold Count = 0
    Lock Object Name = 28
    Object Type = Row
    Tablespace Name = USERSPACE1
    Table Schema = xx
    Table Name = xx
    Mode = U

    Lock Name = 0x0200270100000 0000000000054
    Lock Attributes = 0x00000000
    Release Flags = 0x00000003
    Lock Count = 2
    Hold Count = 2
    Lock Object Name = 295
    Object Type = Table
    Tablespace Name = USERSPACE1
    Table Schema = xx
    Table Name = xx
    Mode = IX

    after that i will do update on this row, once the update statement
    execute. statement.execu te(sql), i still have a table IX lock there,
    why the commit part not working? i have tried to explicitly call
    conn.commit() still not help. but this will cause us problem since we
    don't want to have IX lock stay after commit. Does this is the way
    work on DB2?

    Lock Name = 0x0200270100000 0000000000054
    Lock Attributes = 0x00000000
    Release Flags = 0x00000003
    Lock Count = 2
    Hold Count = 2
    Lock Object Name = 295
    Object Type = Table
    Tablespace Name = USERSPACE1
    Table Schema = xx
    Table Name = xxx
    Mode = IX
  • Fan Ruo Xin

    #2
    Re: IX lock not released

    I don't use JDBC 2 feature.
    Where can I find the definition of a sensitive cursor? Is it a scroll
    cursor?
    AFAIK, when using updatable cursor, you need turn off the autocommit,
    otherwise you may lose the cursor handle.


    xixi wrote:
    [color=blue]
    > i am using type 4 driver with fp3 on windows 64bit server, auto commit
    > is true, cursor is CS type.
    >
    > i have a sensitive , updatable cursor open and bring back a one row
    > resultset, i get this locklist
    >
    > Lock Name = 0x020027011C000 0000000000052
    > Lock Attributes = 0x00000000
    > Release Flags = 0x00000002
    > Lock Count = 1
    > Hold Count = 0
    > Lock Object Name = 28
    > Object Type = Row
    > Tablespace Name = USERSPACE1
    > Table Schema = xx
    > Table Name = xx
    > Mode = U
    >
    > Lock Name = 0x0200270100000 0000000000054
    > Lock Attributes = 0x00000000
    > Release Flags = 0x00000003
    > Lock Count = 2
    > Hold Count = 2
    > Lock Object Name = 295
    > Object Type = Table
    > Tablespace Name = USERSPACE1
    > Table Schema = xx
    > Table Name = xx
    > Mode = IX
    >
    > after that i will do update on this row, once the update statement
    > execute. statement.execu te(sql), i still have a table IX lock there,
    > why the commit part not working? i have tried to explicitly call
    > conn.commit() still not help. but this will cause us problem since we
    > don't want to have IX lock stay after commit. Does this is the way
    > work on DB2?
    >
    > Lock Name = 0x0200270100000 0000000000054
    > Lock Attributes = 0x00000000
    > Release Flags = 0x00000003
    > Lock Count = 2
    > Hold Count = 2
    > Lock Object Name = 295
    > Object Type = Table
    > Tablespace Name = USERSPACE1
    > Table Schema = xx
    > Table Name = xxx
    > Mode = IX[/color]

    Comment

    • Fan Ruo Xin

      #3
      Re: IX lock not released

      WITH HOLD... WITH HOLD... WITH HOLD...

      xixi wrote:
      [color=blue]
      > i am using type 4 driver with fp3 on windows 64bit server, auto commit
      > is true, cursor is CS type.
      >
      > i have a sensitive , updatable cursor open and bring back a one row
      > resultset, i get this locklist
      >
      > Lock Name = 0x020027011C000 0000000000052
      > Lock Attributes = 0x00000000
      > Release Flags = 0x00000002
      > Lock Count = 1
      > Hold Count = 0
      > Lock Object Name = 28
      > Object Type = Row
      > Tablespace Name = USERSPACE1
      > Table Schema = xx
      > Table Name = xx
      > Mode = U
      >
      > Lock Name = 0x0200270100000 0000000000054
      > Lock Attributes = 0x00000000
      > Release Flags = 0x00000003
      > Lock Count = 2
      > Hold Count = 2
      > Lock Object Name = 295
      > Object Type = Table
      > Tablespace Name = USERSPACE1
      > Table Schema = xx
      > Table Name = xx
      > Mode = IX
      >
      > after that i will do update on this row, once the update statement
      > execute. statement.execu te(sql), i still have a table IX lock there,
      > why the commit part not working? i have tried to explicitly call
      > conn.commit() still not help. but this will cause us problem since we
      > don't want to have IX lock stay after commit. Does this is the way
      > work on DB2?
      >
      > Lock Name = 0x0200270100000 0000000000054
      > Lock Attributes = 0x00000000
      > Release Flags = 0x00000003
      > Lock Count = 2
      > Hold Count = 2
      > Lock Object Name = 295
      > Object Type = Table
      > Tablespace Name = USERSPACE1
      > Table Schema = xx
      > Table Name = xxx
      > Mode = IX[/color]

      Comment

      Working...