how can we implement locks in plsql?
Answer / Chandra Dev Pankaj
In PL/SQL, you can implement database locks to prevent concurrent access and modifications to shared data. This is typically done using the DBMS_LOCK package. Here's an example of how to acquire a row lock for a specific record in a table:
BEGIN
dbms_lock.request(type => dbms_lock.row_lock, name => 'MY_LOCK', mode => dbms_lock.exclusive);
SELECT * FROM MY_TABLE WHERE ROWID = :myRowId FOR UPDATE; -- modify the data here
COMMIT;
dbms_lock.release(name => 'MY_LOCK');
END;
| Is This Answer Correct ? | 0 Yes | 0 No |
code for connection from windows forms to sql server
What binary value will be internally stored for NULL for the type S9(1) COMP 3 in mainframe
What is good attributes of Programming language ?
what are the advantages of sap on other software ?
Building Quotation engine program
how to study PHP my own? i reffered many sites.. but as being a fresher i couldnt follow those... which site will be the best one?
you have an unlimited supply of $3 and $7 poker chips. What is the largest integer value that you cannot make by combining different numbers of chips?
Artficial language is provided which of the language?
is try block possible without catch block?
what are the activities you enjoy most and How do you see these Developing in the Future with Reference to in your work life and in your personal life
I have try to write a record in a TDQ from a fle.... what are the steps to do... can anybody plz come with a solution
which book we learned this mantis? how many version are realsed this mantis upto now?