[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

FRM-40655: SQL Error forced Rollback

Posted on 2001-06-15
5
Medium Priority
?
4,790 Views
Last Modified: 2007-11-27
Im getting the following error message

FRM-40655: SQL Error forced Rollback: clear form and re-enter transaction.

I cant understand what is causing it. Can anybody help?

Using Forms Version 6.0.5.0.2 on Win98 connection to Oracle8.1.5

Thanks
0
Comment
Question by:HuzaifaMerchant
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 2

Accepted Solution

by:
renuraj earned 300 total points
ID: 6195790
This happens due to dead lock situation.

To avoid this problem, add NOWAIT option to the UPDATE and DELETE statements, which returns ORA-00054 error, trap this error and display user defined message like 'The record is being accessed and try after some time'.

This even improves the performance because no process waits for the locks preventing dead locks.

If it is due to the UPDATE's or DELETE's with base table blocks in the form, in the PRE-UPDATE and PRE-DELETE triggers write SELECT statements to select the particular row with FOR UPDATE NO WAIT option.  Handle by trapping the ORA-00054 error.

Regards,
0
 

Author Comment

by:HuzaifaMerchant
ID: 6196054
I was hoping that this would solve the problem but it doesnt.

The pre-update trigger
DECLARE
     table_row table_name%ROWTYPE;
     unable_to_lock EXCEPTION;
     PRAGMA EXCEPTION_INIT(unable_to_lock, -00054);
BEGIN
     SELECT *
     INTO   table_row
     FROM   table_name
     WHERE  pk_column = :block.pk_column
     FOR UPDATE NOWAIT;
     
EXCEPTION
     WHEN unable_to_lock THEN
          message('unable to lock');
END;
     
goes through ok, but still does not commit.

Any ideas?
Thanks
0
 

Author Comment

by:HuzaifaMerchant
ID: 6196055
I was hoping that this would solve the problem but it doesnt.

The pre-update trigger
DECLARE
     table_row table_name%ROWTYPE;
     unable_to_lock EXCEPTION;
     PRAGMA EXCEPTION_INIT(unable_to_lock, -00054);
BEGIN
     SELECT *
     INTO   table_row
     FROM   table_name
     WHERE  pk_column = :block.pk_column
     FOR UPDATE NOWAIT;
     
EXCEPTION
     WHEN unable_to_lock THEN
          message('unable to lock');
END;
     
goes through ok, but still does not commit.

Any ideas?
Thanks
0
 
LVL 2

Expert Comment

by:renuraj
ID: 6197791
Hi,

By handling this error, oracle will not allow you to commit the records.

In fact, it avoids the dead lock situation and stops the user to wait for a long time.

When the system displays such a message "Unable to lock", that means oracle cannot acquire lock in that moment because that record is being used by another session.

When it can acquire lock, system allows to perform the manipulation and commits the changes.

Only use of handling this oracle error message is to avoid dead locks.  As soon as the resources are released, the same operation can be performed successfully.

Regards,
0
 

Author Comment

by:HuzaifaMerchant
ID: 6228978
I really donot know what was causing this problem. I was working on an existing form and could not make too many changes to it. I was able to make a new form with the same functionality and it works.

Thanks for your help.
0

Featured Post

Ask an Anonymous Question!

Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
This video explains at a high level with the mandatory Oracle Memory processes are as well as touching on some of the more common optional ones.
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question