Locking And Unlocking Tables In Oracle

August 4th, 2015, posted in Oracle Queries
Share

Locking And Unlocking Tables In Oracle,Locking Tables In Oracle,Unlocking Tables In Oracle,Tables In Oracle,Oracle DBA,DBA,APPS DBA,ORA DBA,Application DBA,Database DBA,Oracle Tricks,Locking Query in Oracle,Unlocking Query in DBA,Oracle Forms Error,Oracle Application Forms Error,Forms : Could not reserve record (2 tries). Keep trying,FRM-40501,FRM-40501: COULD NOT RESERVE RECORD [2 TRIES]; ORACLE APPS RECORD-LOCKING

One Way : 

Oracle puts locks while performing any DDL or DML operation on oracle tables.When table locks is present on any tables in Oracle we cannot run DDL on those tables.

Some of the locks automatically set by oracle are RS and RX Locks.

SELECT … FOR UPDATE execution results in RS (row share) table lock. When you execute an INSERT, UPDATE or DELETE Oracle puts RX (row exclusive) table lock.

We have to kill the session which holds the lock in order to execute further operations. Follow the below steps to kill the session and forcibly unlock the table.

Let’s assume that ‘EMP’ table is locked,

 

SELECT object_id FROM dba_objects WHERE object_name='EMP';
 OBJECT_ID
----------
   7401242

If there are no locks present for the table ‘EMP’ this query won’t return any values.

SELECT sid FROM v$lock WHERE id1=7401242
SID
----------
3434

 

SELECT sid, serial# from v$session where sid=3434
SID        SERIAL#
---------- ----------
3434       92193

 

ALTER SYSTEM KILL SESSION '3434,92193' ;

 

Once the session is killed you will be able to carry out any DDL activities on EMP table. Also you can check in TOAD if there are any active sessions associated to the SID that we killed, to make sure that the session has been killed.

 

 

*********************************************************************************************************************
Also Check : http://aliimmam.com/forms-could-not-reserve-record-2-tries-keep-trying/
Also Check : http://aliimmam.com/lock-tables-and-unlock-tables-syntax/
Note : Please not do make backups before using these queries and also confirm them yourself or by aother means as well. Source : http://www.bluegecko.net/oracle/frm-40501-could-not-reserve-record-2-tries-oracle-apps-record-locking/
*********************************************************************************************************************
Share

I Will Always Be Married To Sea

August 4th, 2015, posted in BoYs, COMiCS, LoVE, POEPLes
Share

I Will Always Be Married To Sea,I Will Always Be ,Married To Sea,married,sea,marry,test,mental test,schizophrenia test online free,schizophrenia test ,online free,online,free,help


http://www.schizoid.info/

Share

Guy Smoking

August 3rd, 2015, posted in Art, No Smoking
Share

Dying Marlboro, marlboro, my cigarette ,criminal-last-of-the-innocent-smoking,cigarette ,no smoking,smoking,smoke, Smoking, wish

To clear up all the confusion, you shouldn’t quit good things like rehab, and you should quit bad things like smoking.

Share

Pakistan Tour Of Srilanka

August 2nd, 2015, posted in DAtEs iN a YeAR, PAKiSTAN
Share

Pakistan tour of Srilanka:
Three captains.
Three series wins.
Three sixes to seal the victory.

Share

Inhalling Cancer Stick Is As Deadly As Ingesting

August 2nd, 2015, posted in Art, MESSAGEs, No Smoking, POEtRY..
Share

Inhalling Cancer Stick Is As Deadly As Ingesting,smoke, loaded gun, loaded gun in your mouth,suicidal,smoke,drug kills,durgs,grave,soul,watching,smoking, dreams, Dying Marlboro, Guy Smoking,lover, marlboro, miss you, my cigarette, my dream, my dreams, no smoking, smoke, Smoking, smoking and missing you, smoking and thinking, smoking and thinking about you, Smoking cigarette,

Share