Job Seekers   Employers
dbapool: Authors | Submissions | Contact Us
   Forgot password? | Sign up
  Home   Discussion Forum   Articles   Interview Questions   FAQs   Scripts   Rewards   Analyzer   White Papers   Blog   Certification   Downloads   Tools
 

Topic: SQL*Plus and PL/SQL >> ORA-40509

Disclaimer: The purpose of all dbapool forums including OCP and Other Oracle Certification forums is to help each other with specific issues but not to share dump and copyrighted exam content, materials or intellectual property. You may review the entire Oracle Certification Program Candidate Agreement online Here.



  


 Title: ORA-40509
 priya  Posted: Jul 05, 2007 02:22:08 AM

 Total Post: 39
 Joined: Apr, 2007






 hi,

can anyone tell me wats the error ORA-40509 is?

i am facing this error while i am trying to save the record.

Thanks
pri

 Nirmal
Posted: Jul 05, 2007 03:06:26 AM  

 Total Post: 10
 Joined: Mar, 2006






 
You tried to execute a LOCK TABLE or SELECT FOR UPDATE command with the NOWAIT
keyword but the resource was unavailable.

Wait and try the command again after a few minutes.
or
Execute the command without the NOWAIT keyword.

Let's say we have 2 session, one session updates a table:

SQL> create table test (n number);

Table created.

SQL> insert into test values(1);

1 row created.

SQL> commit;

Commit complete.

SQL> update test set n=2;

1 row updated.

--> NO COMMIT yet


Now, the other session is trying to select a record for update:
eg:

SQL> declare
2 n number;
3 begin
4 select n into n from test for update nowait;
5 end;
6 /
declare
*
ERROR at line 1:
ORA-00054: resource busy and acquire with NOWAIT specified
ORA-06512: at line 4



 Time Zone: EDT

  




Forum Rules & Description


Who Can Read The Forum? Any registered user or guest
Who Can Post New Topics? Any registered user
Who Can Post Replies? Any registered user




 








Get FREE Magazines

Top 10 Forum User

  Murtuja Khokhar857
  Mohammed Taj746
  positive fanatic483
  Jayanta Sur479
  Vigyan Kaushik386
  Gopu Gopi333
  Gitesh Trivedi322
  Vinoth Kumar264
  neeraj sharma258
  Ramesh Jois246






oracle Mag



  About Us Advertise Terms of Use Privacy Newsletters Contact Us    

Home   Discussion Forum   FAQs  Articles  Jobs   Newsletters  Directory  Downloads 

Our Premium Sponsor
Confio Software