-1

I am just trying to drop the table but getting error. I have just created hbm files of it and checkin the code now that server has been started pointing to the same db. Looks to session got locked. I am getting below error.

Error starting at line 1 in command:
alter table DM_PKG_TEMPLATE drop column INSP_STAGE_ID
Error report:
SQL Error: ORA-00054: resource busy and acquire with NOWAIT specified
00054. 00000 -  "resource busy and acquire with NOWAIT specified"
*Cause:    Resource interested is busy.
*Action:   Retry if necessary.
Vimal Panchal
  • 301
  • 1
  • 5
  • 15
  • 1
    Maybe another transaction didn't commit? – sagi Feb 16 '16 at 09:06
  • Thank you for quick reply. But I can execute the select query on that table – Vimal Panchal Feb 16 '16 at 09:11
  • Select will work.. try to insert/update and tell me if it works.. If not, then this table is busy in another transaction(maybe another window or another user) – sagi Feb 16 '16 at 09:12
  • 2
    The fact that you can select from the table doesn't mean some other transaction didn't update/delete/insert from that table. In Oracle writers do not block readers. –  Feb 16 '16 at 09:15
  • In Oracle, writers do not block readers and vice-versa. – Lalit Kumar B Feb 16 '16 at 09:55

1 Answers1

0

Execute the given query to check if your table is in Lock. if locked kill the session and drop the column.

SELECT A.SID,A.SERIAL#,A.OSUSER,A.PROCESS,C.OBJECT_NAME
  FROM V$SESSION A,V$LOCKED_OBJECT B,DBA_OBJECTS C
 WHERE A.SID = B.SESSION_ID
   AND B.OBJECT_ID = C.OBJECT_ID
   AND C.OBJECT_NAME LIKE '%PDM_PKG_TEMPLATE%'
Bhaskar
  • 1
  • 1