Error Could not reserver record

To discuss Oracle Forms & Reports related technical issues.
Post Reply
najm
Posts: 74
Joined: Wed Apr 05, 2006 8:04 am
Location: Pakistan

Error Could not reserver record

Post by najm »

I face following error very frequently in my Database

<b>Could not reserver record (2 tries). keeb trying?</b>

i know why it show but i want to know how fix it.

Thanks.
ahmadbilal
Posts: 615
Joined: Mon Sep 18, 2006 1:32 am
Location: United Arab Emirates
Contact:

Post by ahmadbilal »

get trace of oracle forms by using Oracle Trace and then check which record is get locked for more help please review
www.oracle.com/technology/products/forms/pdf/275144.pdf


By suppressing FRM-40501 you are defining the lock functionality to be
NO-WAIT. If the record is locked by another user, then do not wait for the
lock to be released, which basically implements the same behavior as pressing
the "NO" button on the Form alert.
For example: ON-LOCK Trigger : BLOCK Level

DECLARE
dummy VARCHAR2(1);
could_not_lock EXCEPTION;

/* Define Exception for ORA-00054, which occurs when an attempt */
/* is made to lock an already locked record. */
PRAGMA EXCEPTION_INIT (could_not_lock, -54);
BEGIN
SELECT 'X'
INTO dummy
FROM dept /* this is the table you are trying to access */
WHERE rowid = :dept.rowid
FOR UPDATE OF deptno NOWAIT;

MESSAGE('Locked Current Row ');

EXCEPTION
WHEN could_not_obtain_lock THEN
MESSAGE('Record locked by another user. Try Again Later');
RAISE FORM_TRIGGER_FAILURE;
END;
Post Reply

Who is online

Users browsing this forum: No registered users and 5 guests