How to resolve ORA-00060: deadlock detected in Workflow
Hi there,
I have defined a custom workflow which initiated from Trigger
AFTER UPDATE of status_code ON pa.pa_proj_elements
The WF activities includes:
-Set item attributes
-Find users and add users to adhoc role
-Send Action & FYI notification
-Update status_code using standard API PA_PROGRESS_PUB.UPDATE_PROGRESS, this API will add a new role in pa_percent_completes table.
But the API failed to update the status_code with the following error:
ORA-00060: deadlock detected while waiting for resource in Package PA_PROGRESS_PUB Procedure UPDATE_PROGRESS...
Please help.
sorry, typo mistake on the standard API will in fact create a row in pa_percent_completes table.
Similar Messages
-
ORA-00060: Deadlock detected
I getting error as "ORA-00060: Deadlock detected. More info in file /d01/oracle/VIS/db/tech_st/10.2.0/.................". Following are my observations on the occurence of this error.
The deadlock is encountered first time when trying to login to applications. I have R12 vision instance on linux.
Following the content of the alert_VIS.log file
Mon Jun 15 04:41:41 2009
Starting ORACLE instance (normal)
LICENSE_MAX_SESSION = 0
LICENSE_SESSIONS_WARNING = 0
Picked latch-free SCN scheme 3
Using LOG_ARCHIVE_DEST_1 parameter default value as /d01/oracle/VIS/db/tech_st/10.2.0/dbs/arch
Autotune of undo retention is turned on.
IMODE=BR
ILAT =44
LICENSE_MAX_USERS = 0
SYS auditing is disabled
ksdpec: called for event 13740 prior to event group initialization
Starting up ORACLE RDBMS Version: 10.2.0.3.0.
System parameters with non-default values:
tracefiles_public = TRUE
processes = 200
sessions = 400
timed_statistics = TRUE
shared_pool_size = 419430400
shared_pool_reserved_size= 41943040
nls_language = american
nls_territory = america
nls_sort = binary
nls_date_format = DD-MON-RR
nls_numeric_characters = .,
nls_comp = binary
nls_length_semantics = BYTE
sga_target = 1073741824
control_files = /d01/oracle/VIS/db/apps_st/data/cntrl01.dbf, /d01/oracle/VIS/db/apps_st/data/cntrl02.dbf, /d01/oracle/VIS/db/apps_st/data/cntrl03.dbf
db_block_checksum = TRUE
db_block_size = 8192
compatible = 10.2.0
log_buffer = 14251008
log_checkpoint_interval = 100000
log_checkpoint_timeout = 1200
db_files = 512
log_checkpoints_to_alert = TRUE
dml_locks = 10000
undo_management = AUTO
undo_tablespace = APPS_UNDOTS1
db_block_checking = FALSE
O7_DICTIONARY_ACCESSIBILITY= FALSE
session_cached_cursors = 500
utl_file_dir = /usr/tmp, /usr/tmp, /d01/oracle/VIS/db/tech_st/10.2.0/appsutil/outbound/VIS_oracleebsr12, /usr/tmp
plsql_native_library_dir = /d01/oracle/VIS/db/tech_st/10.2.0/plsql/nativelib
plsql_native_library_subdir_count= 149
plsql_code_type = native
plsql_optimize_level = 2
job_queue_processes = 2
systemtrig_enabled = TRUE
cursor_sharing = EXACT
parallel_min_servers = 0
parallel_max_servers = 8
background_dump_dest = /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/bdump
user_dump_dest = /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/udump
max_dump_file_size = 20480
core_dump_dest = /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/cdump
db_name = VIS
open_cursors = 600
ifile = /d01/oracle/VIS/db/tech_st/10.2.0/dbs/VIS_oracleebsr12_ifile.ora
sortelimination_cost_ratio= 5
btree_bitmap_plans = FALSE
fastfull_scan_enabled = FALSE
sqlexecprogression_cost= 2147483647
likewith_bind_as_equality= TRUE
pga_aggregate_target = 1073741824
workarea_size_policy = AUTO
optimizer_secure_view_merging= FALSE
aq_tm_processes = 1
olap_page_pool_size = 4194304
Mon Jun 15 04:42:05 2009
WARNING:Oracle instance running on a system with low open file descriptor
limit. Tune your system to increase this limit to avoid
severe performance degradation.
PSP0 started with pid=3, OS id=6824
PMON started with pid=2, OS id=6822
MMAN started with pid=4, OS id=6826
DBW0 started with pid=5, OS id=6828
CKPT started with pid=7, OS id=6832
SMON started with pid=8, OS id=6834
RECO started with pid=9, OS id=6836
CJQ0 started with pid=10, OS id=6838
LGWR started with pid=6, OS id=6830
MMON started with pid=11, OS id=6840
MMNL started with pid=12, OS id=6842
Mon Jun 15 04:42:19 2009
ALTER DATABASE MOUNT
Mon Jun 15 04:42:25 2009
Setting recovery target incarnation to 2
Mon Jun 15 04:42:27 2009
Successful mount of redo thread 1, with mount id 243370348
Mon Jun 15 04:42:27 2009
Database mounted in Exclusive Mode
Completed: ALTER DATABASE MOUNT
Mon Jun 15 04:42:28 2009
ALTER DATABASE OPEN
Mon Jun 15 04:42:48 2009
Thread 1 opened at log sequence 16
Current log# 3 seq# 16 mem# 0: /d01/oracle/VIS/db/apps_st/data/log3.dbf
Successful open of redo thread 1
Mon Jun 15 04:42:48 2009
MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set
Mon Jun 15 04:42:48 2009
SMON: enabling cache recovery
Mon Jun 15 04:42:48 2009
Incremental checkpoint up to RBA [0x10.a779.0], current log tail at RBA [0x10.a779.0]
Mon Jun 15 04:43:01 2009
Successfully onlined Undo Tablespace 18.
Mon Jun 15 04:43:01 2009
SMON: enabling tx recovery
Mon Jun 15 04:43:04 2009
Database Characterset is UTF8
Mon Jun 15 04:43:18 2009
replication_dependency_tracking turned off (no async multimaster replication found)
Mon Jun 15 04:43:44 2009
Starting background process QMNC
QMNC started with pid=14, OS id=6884
Mon Jun 15 04:46:48 2009
Completed: ALTER DATABASE OPEN
Mon Jun 15 05:03:23 2009
Incremental checkpoint up to RBA [0x10.b1bd.0], current log tail at RBA [0x10.b1f3.0]
Mon Jun 15 05:23:33 2009
Incremental checkpoint up to RBA [0x10.b5b3.0], current log tail at RBA [0x10.b5c2.0]
Mon Jun 15 05:45:12 2009
Incremental checkpoint up to RBA [0x10.b7b0.0], current log tail at RBA [0x10.fbce.0]
This is upto the point where all DB and application services has been started.
Once trying to login to applications following content got appended to the log file
Mon Jun 15 05:53:39 2009
ORA-00060: Deadlock detected. More info in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/udump/vis_ora_8149.trc.
Mon Jun 15 05:53:51 2009
ORA-00060: Deadlock detected. More info in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/udump/vis_ora_8149.trc.
Mon Jun 15 05:54:02 2009
ORA-00060: Deadlock detected. More info in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/udump/vis_ora_8149.trc.
Mon Jun 15 05:54:12 2009
ORA-00060: Deadlock detected. More info in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/udump/vis_ora_8149.trc.
Mon Jun 15 05:54:22 2009
ORA-00060: Deadlock detected. More info in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/udump/vis_ora_8149.trc.
Mon Jun 15 05:54:28 2009
ORA-00060: Deadlock detected. More info in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/udump/vis_ora_8149.trc.
Mon Jun 15 05:54:35 2009
ORA-00060: Deadlock detected. More info in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/udump/vis_ora_8149.trc.
Mon Jun 15 05:54:42 2009
ORA-00060: Deadlock detected. More info in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/udump/vis_ora_8149.trc.
Mon Jun 15 05:59:06 2009
Process J000 died, see its trace file
Mon Jun 15 05:59:11 2009
kkjcre1p: unable to spawn jobq slave process
Mon Jun 15 05:59:11 2009
Errors in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/bdump/vis_cjq0_6838.trc:
Mon Jun 15 05:59:23 2009
Process J000 died, see its trace file
Mon Jun 15 05:59:24 2009
kkjcre1p: unable to spawn jobq slave process
Mon Jun 15 05:59:24 2009
Errors in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/bdump/vis_cjq0_6838.trc:
Mon Jun 15 05:59:50 2009
Process J000 died, see its trace file
Mon Jun 15 05:59:50 2009
kkjcre1p: unable to spawn jobq slave process
Mon Jun 15 05:59:50 2009
Errors in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/bdump/vis_cjq0_6838.trc:
I did the TKPROF on .trc files but the tkprof file does not show any details as such except similar to :- (don't know if I am missing anything while issuing TKPROF as $ tkprof filename.trc
filename.txt explain=apps/apps)
TKPROF: Release 10.2.0.3.0 - Production on Mon Jun 15 06:07:14 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Trace file: /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/bdump/vis_cjq0_6838.trc
Sort options: default
count = number of times OCI procedure was executed
cpu = cpu time in seconds executing
elapsed = elapsed time in seconds executing
disk = number of physical reads of buffers from disk
query = number of buffers gotten for consistent read
current = number of buffers gotten in current mode (usually for update)
rows = number of rows processed by the fetch or execute call
0 statements EXPLAINed in this session.
Trace file: /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/bdump/vis_cjq0_6838.trc
Trace file compatibility: 10.01.00
Sort options: default
1 session in tracefile.
0 user SQL statements in trace file.
0 internal SQL statements in trace file.
0 SQL statements in trace file.
0 unique SQL statements in trace file.
22 lines in trace file.
0 elapsed seconds in trace file.
Yesterday, I did login to applications after multiple attempts and tried submitting a concurrent request of a standard report (after resolving the data block corrupt issue) and got the same ORA-00060 Error.
I have a fresh VISION R12 (12.0.4) installed without any customizations. My installation looks to be quite unstable, takes 2-3 attempts for successful login to apps.
Can you please give any clues on this and how to overcome the problem?
Thanks,
AmitI have run cmclean.sql as per :- Re: R12 Vision install - Unable to submit concurrent request
This is the only change made. No new patches etc. Before running cmclean.sql I believe the instance was working fine.
Now everytime I start the application services, its causing ORA=00060: Deadlock error. There are no issues with just DB services up and running.
And after apps services up, when trying to Login to apps it just hangs, get error as follows:
Tue Jun 23 02:04:55 2009
Process J001 died, see its trace file
Tue Jun 23 02:04:55 2009
kkjcre1p: unable to spawn jobq slave process
Tue Jun 23 02:04:55 2009
Errors in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/bdump/vis_cjq0_6747.trc:
Tue Jun 23 02:05:04 2009
Process q002 died, see its trace file
Tue Jun 23 02:05:04 2009
ksvcreate: Process(q002) creation failed
Tue Jun 23 02:05:55 2009
Process J000 died, see its trace file
Tue Jun 23 02:05:55 2009
kkjcre1p: unable to spawn jobq slave process
Tue Jun 23 02:05:55 2009
Errors in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/bdump/vis_cjq0_6747.trc:
Tue Jun 23 02:06:11 2009
Process J000 died, see its trace file
Tue Jun 23 02:06:11 2009
kkjcre1p: unable to spawn jobq slave process
Tue Jun 23 02:06:11 2009
Errors in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/bdump/vis_cjq0_6747.trc:
Tue Jun 23 02:08:51 2009
Process J000 died, see its trace file
Tue Jun 23 02:08:52 2009
kkjcre1p: unable to spawn jobq slave process
Tue Jun 23 02:08:52 2009
Errors in file /d01/oracle/VIS/db/tech_st/10.2.0/admin/VIS_oracleebsr12/bdump/vis_cjq0_6747.trc:
The OS also hangs (Linux) and I have to exit abnormally everytime which is frustrating.
I am not sure the reason for the same. I have gone through the metalink notes pointed which says to install the health check engine.
Do you have any clues based on above information as to what might be causing this problem.
I have 4 GB RAM installed on my Windows and 2 GB has been allocated to Linux on VMware.
Please let me know if I need to upgrade the memory.
Any pointers would be really helpful.
Thanks,
Amit -
How to overcome thisORA-00060: deadlock detected while waiting for resource
Hi ,
I have table name problems(prom_number,prom_relation,prom_impact,prom_prom_number)
Now from oracle form raltion can be set.
parent and chil relation can be set from the form
for ex
first suppose row=1 prom_number=1 is set as parent.
so the tabl is updated as prom_+relation='PARENT'
so after first updation values are
prom_number=1,prom_impact='xxx',prom_relation='PARENT' prom_prom_number=null
now in form level the 2 row which is set as child is update as follow
prom_number=2,prom_impact='yyy',prom_relation='CHILD' prom_prom_number=1
Now my requirment is after the 2nd row is updated the prom_impact of 2 row should be pusehd to row=1 which has the pirom_relation as ='PARENT.
the problem is i dont have the fmb of form so i cant do any changes in the form.
So i have written a trigger which fires when row2 is updated it picks the prom_impact value and trys to push it in row=1 with prom_number=1
however since in form level the table has not been committed it displays the following error
ORA-00060: deadlock detected while waiting for resource
So how can we overcome this error.
the trigger i have written is given below.
So how can we resolve thsis issue.
CREATE OR REPLACE TRIGGER Parent_Child_Impact_Trg
AFTER UPDATE OF prom_relation,prom_prom_number
ON PROBLEMS
REFERENCING NEW AS NEW OLD AS OLD
FOR EACH ROW
Version History:9.2.8.1
(format: version, date, developer, description)
1.0, 19-Dec-2008, Tanmoy Kr Moulik The "Impact" of Paren fault ticket
will be changed upon manual creation of Parent Child relation
Rules:
1.0 Upon manual creation of new Parent-Child fault relation, the 'Fault Impact' of
Child fault will be auto updated in the parent fault, if the parent fault impact matches
with the attached list(Non Serve Affeect or Threat) or the impact of Parent Fault is blank (null).
2.0 In case, the parent fault have fault impact matches with the attached list
(service affect), then its impact is not changed while making the relationship.
DECLARE
PRAGMA autonomous_transaction;
ecode NUMBER;
emesg VARCHAR2(200);
--BEGIN
-- NULL;
CURSOR c1--(v_prom_num NUMBER)
IS
SELECT PROM_IMPACT,prom_number FROM PROBLEMS WHERE prom_number=:NEW.prom_prom_number;
v_prom_imp VARCHAR2(30) DEFAULT NULL;
v_prom_imp_p1 NUMBER DEFAULT 0;
v_prom_imp_p2 NUMBER DEFAULT 0;
v_prom_num NUMBER;
BEGIN
IF :NEW.PROM_RELATION='CHILD' AND :NEW.PROM_PROM_NUMBER IS NOT NULL THEN
--dbms_output.put_line(1);
--INSERT INTO TEMP_PROM VALUES(:NEW.prom_number,:NEW.prom_prom_number,:NEW.prom_impact,:NEW.prom_relation);
--COMMIT;
OPEN c1;--(:NEW.prom_prom_number);
FETCH c1 INTO v_prom_imp,v_prom_num;
--INSERT INTO TEMP_PROM(PROM_NUM,PROM_IMPACT) VALUES(v_prom_num,v_prom_imp);
--COMMIT;
IF c1%NOTFOUND THEN
v_prom_imp:=NULL;
v_prom_num:=NULL;
END IF;
CLOSE c1;
v_prom_imp:=UPPER(v_prom_imp);
v_prom_imp_p1:=INSTR(v_prom_imp,'NON');
v_prom_imp_p2:=INSTR(v_prom_imp,'THREAT');
--INSERT INTO TEMP_PROM(PROM_NUM) VALUES(v_prom_imp_p1);
--INSERT INTO TEMP_PROM(PROM_NUM) VALUES(v_prom_imp_p2);
--COMMIT;
IF v_prom_imp_p1>0 OR v_prom_imp_p2>0 THEN
IF :NEW.prom_impact IS NOT NULL THEN
/*BEGIN
INSERT INTO TEMP_PROM(PROM_NUM,PROM_PROM_NUMBER,prom_impact,PROM_RELATION) VALUES(:NEW.prom_number,:NEW.prom_prom_number,:NEW.prom_impact,:NEW.prom_relation);
COMMIT;
EXCEPTION WHEN OTHERS THEN
INSERT INTO TEMP_PROM(prom_impact,PROM_RELATION) VALUES('failed1'||ecode,emesg);
COMMIT;
END;
BEGIN
COMMIT;
--INSERT INTO PROBLEMS(prom_number,PROM_REPORTED,PROM_REPORTEDBY,PROM_PRIORITY,PROM_DESCRIPTION,PROM_EMPE_ID,PROM_WORG_NAME,PROM_CREATED,PROM_CWORG_NAME)
-- VALUES(50000000,SYSDATE,'TAN',1,'DASD','CLARITY','CLARITY',SYSDATE,'CLARITY');
UPDATE PROBLEMS SET PROM_IMPACT=:NEW.PROM_IMPACT WHERE prom_number=:NEW.prom_prom_number;
COMMIT;
EXCEPTION WHEN OTHERS THEN
ecode := SQLCODE;
emesg := SQLERRM;
COMMIT;
BEGIN
UPDATE PROBLEMS SET PROM_IMPACT=:NEW.PROM_IMPACT WHERE prom_number=:NEW.prom_prom_number;
EXCEPTION WHEN OTHERS THEN
INSERT INTO TEMP_PROM(prom_impact,PROM_RELATION) VALUES('failed'||ecode,emesg);
END;
--INSERT INTO TEMP_PROM(prom_impact,PROM_RELATION) VALUES('failed'||ecode,emesg);
COMMIT;
-- EXCEPTION WHEN OTHERS THEN*/
NULL;
END;
--END;
--END;
END IF;
/*BEGIN
INSERT INTO TEMP_PROM(PROM_NUM,PROM_IMPACT) VALUES(:NEW.prom_prom_number,:NEW.prom_impact);
COMMIT;
EXCEPTION WHEN OTHERS THEN
INSERT INTO TEMP_PROM(prom_impact) VALUES('failed1');
NULL;
END;
--NULL;
-- END;
--COMMIT;
--END;
/* BEGIN
INSERT INTO TEMP_PROM(PROM_NUM,PROM_IMPACT) VALUES(:NEW.prom_prom_number,:NEW.prom_impact);
EXCEPTION WHEN OTHERS THEN
--INSERT INTO TEMP_PROM(prom_impact) VALUES('failed');
NULL;
END;
COMMIT;
--COMMIT;
/* ELSIF v_prom_imp_p2>0 THEN
-- v_prom_imp_p2
IF :NEW.prom_impact IS NOT NULL THEN
BEGIN
UPDATE PROBLEMS SET PROM_IMPACT=:NEW.PROM_IMPACT WHERE prom_number=:NEW.prom_prom_number;
EXCEPTION WHEN OTHERS THEN
BEGIN
ecode := SQLCODE;
emesg := SQLERRM;
--BEGIN
INSERT INTO TEMP_PROM(prom_impact,PROM_RELATION) VALUES('failed'||ecode,emesg);
COMMIT;
--EXCEPTION WHEN OTHERS THEN
NULL;
END;
NULL;
END;
COMMIT;
BEGIN
INSERT INTO TEMP_PROM(PROM_NUM,PROM_IMPACT) VALUES(:NEW.prom_prom_number,:NEW.prom_impact);
EXCEPTION WHEN OTHERS THEN
NULL;
END;
COMMIT;*/
--UPDATE PROBLEMS SET PROM_IMPACT=:NEW.PROM_IMPACT WHERE prom_number=:NEW.prom_prom_number;
-- COMMIT;
-- END IF;
END IF;
END IF;
EXCEPTION WHEN OTHERS THEN
INSERT INTO TEMP_PROM(prom_impact,PROM_RELATION) VALUES('failed2'||ecode,emesg);
COMMIT;
NULL;
END;
/Please do not take this the wrong way, my intention is not to be insulting, but from reading what you've posted I have no idea what you are doing or in what version of what product(s).
What I can tell you, though, is that your explicit cursor declarations with explicit OPEN and FETCH have no business in your code. Neither do incremental commits belong in any code. Nor does the following:
EXCEPTION WHEN OTHERS THEN
INSERT INTO TEMP_PROM(prom_impact,PROM_RELATION) VALUES('failed2'||ecode,emesg);
COMMIT;
NULL;belong in any code. What is NULL doing there? And why are there any commits in your trigger? Your use of PRAGMA AUTONOMOUS TRANSACTION to allow these commits is similarly unexplainable. It is no wonder you are getting deadlocks.
You need to push away from the keyboard and take SQL and PL/SQL courses and learn the basics. While looking for a good course in your area get a copy of any of Tom Kyte's books and start reading it and practicing with the examples. -
Database error"ORA-00060: deadlock detected while waiting for resource"
Hi All,
I got dump as
Database error text........: "ORA-00060: deadlock detected while waiting for
resource"
Internal call code.........: "[RSQL/RDUP/NRIV ]"
Please check the entries in the system log (Transaction SM21).
An exception occurred that is explained in detail below.
The exception, which is assigned to class 'CX_SY_OPEN_SQL_DB', was not caught
in
procedure "READ_NRIV" "(FORM)", nor was it propagated by a RAISING clause.
Can u ppl tell me how to get correct this?
Edited by: Bala Chandar on Jul 20, 2009 11:01 AMHi Bala,
Same type of dump we got when we trigger the DTP which in process chain to load data from DSO to Info cube. And the load had processed with 225 data package and at 164th data package we got this error and except 164th data package all data package processed successfully
And the request was red. So we had done processed manually by clicking the icon. So all its been green and successfully loaded.
So when you do process manual the particular data package which got failed will be process successfully -
ORA-00060: deadlock detected while waiting for resource CLOSE cursor
Hi,
I am a new member of this forum. I am working with a problem we got a few weeks ago. It is from a Pro C batch executable running on 10 threads dealing with >800 data accessed from multiple tables. The error as reported came from a package.function call.
This is the error I encountered:
process_item~G****, D***~-60~ORA-00060: deadlock detected while waiting for resource~PACKAGE ERROR = CLOSE cursor C_***** in package R***.I*** 7641
The cursor is a simple SELECT cursor without Table or Record locking.
My questions are:
*Upon the occurrence of this error, is the execution already at the CLOSE cursor line or did the error occurred between the OPEN cursor and the CLOSE cursor? There are several lines of code in between OPEN and CLOSE:
- one that calls for a package.function that simply stores parameter values to a variable
- another one which fetches the cursor. The group that holds the cursor values is only used by a single function in the package
*Is it possible for this CLOSE cursor to cause a deadlock? What could have caused this?
*From what I know, Oracle deals with deadlocks by aborting the deadlocking process while others continue, but this deadlock caused our program to hang. How is this possible? Could the root cause of the deadlock be from our threading program? This is a rare occurrence and happened only twice this year.
Thanks,
RafRaf Serrano wrote:
Hi,
I am a new member of this forum. I am working with a problem we got a few weeks ago. It is from a Pro C batch executable running on 10 threads dealing with >800 data accessed from multiple tables. The error as reported came from a package.function call.
This is the error I encountered:
process_item~G****, D***~-60~ORA-00060: deadlock detected while waiting for resource~PACKAGE ERROR = CLOSE cursor C_***** in package R***.I*** 7641
The cursor is a simple SELECT cursor without Table or Record locking.
My questions are:
*Upon the occurrence of this error, is the execution already at the CLOSE cursor line or did the error occurred between the OPEN cursor and the CLOSE cursor? There are several lines of code in between OPEN and CLOSE:
- one that calls for a package.function that simply stores parameter values to a variable
- another one which fetches the cursor. The group that holds the cursor values is only used by a single function in the package
*Is it possible for this CLOSE cursor to cause a deadlock? What could have caused this?
*From what I know, Oracle deals with deadlocks by aborting the deadlocking process while others continue, but this deadlock caused our program to hang. How is this possible? Could the root cause of the deadlock be from our threading program? This is a rare occurrence and happened only twice this year.
Thanks,
RafSELECT (without FOR UPDATE) statements are never involved in ORA-00060.
only DML statements throw ORA-00060 error -
Fix for ORA-00060: Deadlock detected errors
Hello APEX community,
in the last days we are hitting more and more frequent the ORA-00060: Deadlock detected error in one of our applications. Logged an SR with Oracle Support but so far not too much help, except pointing to some older bugs:
Bug 6618662: APEX APPEARS TO BE CAUSING DEADLOCK - CASE COLLECTION or Bug 7587013: INSERTING AND DELETING WWV_FLOW_DATA CAUSES DEADLOCK, which do not look at all appealing as the first bug was logged in Nov 2007 and the resolution was delayed from version 3.1, to 4.0 and even to 4.1, while de second was logged in Nov 2008 and not much happened with it.
I am curious how many other users are hitting the same issue and which workarounds found for the problem. For example yesterday I could see 12 such errors in my log, today already 3.
FlorinHi John,
here it is: http://www.moyersoen.be/auction/1442/ or http://www.moyersoen.be/pls/apex/f?p=2008:11:0::::P11_AUCTION_ID:1442. Normally the page response time is < 0.20, but from time to time it goes up to more than 20 seconds and at those times I can see also the ORA-00060: Deadlock detected errors.
Looks like the users are clicking twice refresh for that page. I am trying now to build a testcase that reproduce the issue easily.
Florin -
ORA-00060 - Deadlock detected Error
Hello Gurus,
In Our BW Production Server we are facing follwoing error sice few days
BR0976W Database message alert - level: WARNING, line: 1572623, time: 2008-01-23 01.49.02, message:
ORA-00060: Deadlock detected. More info in file /oracle/PBW/saptrace/usertrace/pbw_ora_590014.trc.
BR0976W Database message alert - level: WARNING, line: 1572637, time: 2008-01-23 01.56.47, message:
ORA-00060: Deadlock detected. More info in file /oracle/PBW/saptrace/usertrace/pbw_ora_598066.trc.
Can anybody tell me the how to get rid of this error
Vital Information - Server
O/S - AIX
SAP Version - 700
Oracle - 10.2.0.2.0
ABAP Support Pack - SAPKA70010
Basis Support Pack - SAPKB70010
Patch - 95
Thanks & Regards
ShishirThe trace file will be written to the directory indicated by the USER_DUMP_DEST init.ora parameter.
The trace file will contain a deadlock graph and additional information similar to that shown below. This is the trace output from the above example which signaled an ORA-60 to Ses#2:
The following deadlock is not an ORACLE error. It is a deadlock due to user error in the design of an application or from issuing incorrect ad-hoc SQL. The following information may aid in determining the deadlock:
Deadlock graph:
Blocker(s)-- -Waiter(s)--
Resource Name process session holds waits process session holds waits
TX-00020012-0000025e 12 11 X 11 10 X
TX-00050013-0000003b 11 10 X 12 11 X
session 11: DID 0001-000C-00000001 session 10: DID 0001-000B-00000001
session 10: DID 0001-000B-00000001 session 11: DID 0001-000C-00000001
Rows waited on:
Session 10: obj - rowid = 00000BF6 - AAAAv2AAEAAAAqKAAB
Session 11: obj - rowid = 00000BF6 - AAAAv2AAEAAAAqKAAA -
ORA-00060: deadlock detected while waiting for resource with Tbs Read-only
Hi all,
We're using Oracle 10.2.0.1 and 9.2.0.4.
I'm testing the performing of a procedure that inserts, like this:
CREATE OR REPLACE PROCEDURE P$TAD_TEST
IS
TYPE T_T1_C1 IS TABLE OF T1.C1%TYPE INDEX BY PLS_INTEGER;
TYPE T_T1_DT IS TABLE OF T1.DT%TYPE INDEX BY PLS_INTEGER;
P_C1 T_T1_C1;
P_DT T_T1_DT;
P_RESULT NUMBER;
BEGIN
FOR j IN 1..4032 LOOP
P_C1(j) := j;
P_DT(j) := SYSDATE + (j/24/60);
END LOOP;
FORALL i IN P_C1.FIRST..P_C1.LAST SAVE EXCEPTIONS
INSERT INTO T1 VALUES (P_C1(i), P_DT(i));
EXCEPTION
WHEN OTHERS THEN
P_RESULT := SQLCODE;
END;
The table T1 is partitioned across 10 tablespaces. The test consist to take
these tablespace read-only and perform the procedure, and analyze the results,
like erros.
but when I perform the procedure, The alert.log indicates the error
ORA-00060: deadlock detected while waiting for resource.
Why this occurs only the tablespaces are read-only?
thank you!!!!Hi,
yesterday we got this error again(in fact twice) and we were able to get the trace file. It says this is NOT oracle error. i was wrong in suspecting Oracle. This is the trace file details. i dont know how to debug this. Any help appreciated.
*** 2010-06-15 16:24:29.243
*** ACTION NAME:() 2010-06-15 16:24:29.231
*** MODULE NAME:(JDBC Thin Client) 2010-06-15 16:24:29.231
*** SERVICE NAME: 2010-06-15 16:24:29.231
*** SESSION ID:(482.4266) 2010-06-15 16:24:29.231
DEADLOCK DETECTED ( ORA-00060 )
[Transaction Deadlock]
The following deadlock is not an ORACLE error. It is a
deadlock due to user error in the design of an application
or from issuing incorrect ad-hoc SQL. The following
information may aid in determining the deadlock:
Deadlock graph:
---------Blocker(s)-------- ---------Waiter(s)---------
Resource Name process session holds waits process session holds waits
TX-00300021-0000b52d 209 482 X 247 474 S
TX-002a0009-00011b24 247 474 X 209 482 S
session 482: DID 0001-00D1-0000000A session 474: DID 0001-00F7-00000008
session 474: DID 0001-00F7-00000008 session 482: DID 0001-00D1-0000000A
Rows waited on:
Session 474: obj - rowid = 0000CED4 - AAAM7UAAxAAAVgSAAA
(dictionary objn - 52948, file - 49, block - 88082, slot - 0)
Session 482: obj - rowid = 0000D8BF - AAANi/AAuAAB+z/AAA
(dictionary objn - 55487, file - 46, block - 519423, slot - 0)
Information on the OTHER waiting sessions:
Session 474:
pid=247 serial=31796 audsid=25502259 user: 62/USER
O/S info: ....
program: JDBC Thin Client
application name: JDBC Thin Client, hash value=2546894660
Current SQL Statement:
INSERT QUERY1
End of information on OTHER waiting sessions.
Current SQL statement for this session:
INSERT QUERY2
Thanks,
AK -
ORA-00060: deadlock detected while adding a datafile
Hello all,
I found a strange error today.
We were trying add datafile to our existing tablespace as usually but suddenly caught in a problem.
SQL> alter tablespace erp_dat2 add datafile '/hotdata2/irsdata/erp_dat2irs_145.dbf' size 2000M;
alter tablespace erp_dat2 add datafile '/hotdata2/irsdata/erp_dat2irs_145.dbf' size 2000M
ERROR at line 1:
ORA-00060: deadlock detected while waiting for resourcelooks very strange.Searched on google but not found something useful.Still searching.No trace file is generated as such.
Any ideas will be appreciated. Is it related to any batch job running?
OS : SunOS 5.10 Generic_142900-13 sun4u sparc SUNW,Sun-Fire (64-bit)
RDBMS : 11.1.0.7
Regards!
Edited by: Nitin Joshi on Sep 30, 2010 3:41 PM
Changed subject lineseems like you're hitting a bug in 11.1.0.7
Bug 8332021 - Cannot add a datafiles when sessions reporting ORA-1653 [ID 8332021.8]
ORA-60 can occur during datafile addition when concurrent sessions
are reporting ORA-1653 .>>Workaround:
>> Stop the sessions getting the errors then add the datafile. -
Hi,
I'm getting following exception:
Caused by: net.sf.hibernate.exception.GenericJDBCException: could not update: [com.sample.database.hibernate.mappings.reference.impl.TaskImpl#156979998]
at net.sf.hibernate.exception.ErrorCodeConverter.handledNonSpecificException(ErrorCodeConverter.java:90)
at net.sf.hibernate.exception.ErrorCodeConverter.convert(ErrorCodeConverter.java:79)
at net.sf.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:30)
at net.sf.hibernate.persister.AbstractEntityPersister.convert(AbstractEntityPersister.java:1332)
at net.sf.hibernate.persister.EntityPersister.update(EntityPersister.java:683)
at net.sf.hibernate.persister.EntityPersister.update(EntityPersister.java:623)
at net.sf.hibernate.impl.ScheduledUpdate.execute(ScheduledUpdate.java:52)
at net.sf.hibernate.impl.SessionImpl.executeAll(SessionImpl.java:2438)
at net.sf.hibernate.impl.SessionImpl.execute(SessionImpl.java:2392)
at net.sf.hibernate.impl.SessionImpl.flush(SessionImpl.java:2260)
at net.sf.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:61)
at com.sample.database.hibernate.util.HibernateUtil.doSessionWork(HibernateUtil.java:83)
... 8 more
Caused by: java.sql.SQLException: ORA-00060: deadlock detected while waiting for resource
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:158)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:305)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:272)
at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:623)
at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:181)
at oracle.jdbc.driver.T4CPreparedStatement.execute_for_rows(T4CPreparedStatement.java:685)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1138)
at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3018)
at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:3090)
at com.mchange.v2.sql.filter.FilterPreparedStatement.executeUpdate(FilterPreparedStatement.java:71)
at net.sf.hibernate.persister.EntityPersister.update(EntityPersister.java:666)
... 15 more
what could be the reason??
thanks.The error is coming from an application. Please check the alert log file of the database and further there will be a trace file mentioned in the alert log file in which you will have information of the object which is causing deadlock.
Regards -
Java.sql.SQLException: ORA-00060: deadlock detected
We are getting this error "java.sql.SQLException: ORA-00060: deadlock detected while waiting for resource"
Application tester is receiving this error what is problem/solution?Metalink Note:146580.1
-
Sqlldr- ORA-00060: deadlock detected while waiting for resource
Hi Team,
My database version is 11.1.0.7.0. I am loading the data using sqlldr. I am getting the error ORA-00060: deadlock detected while waiting for resource. once dead lock detected ,whether data will be rejected after commit point reached(Rows=100000). FYI information only sqllder is running on the database,it is getting completed withing 5-10min. please help me whether any other lock happening on this due to sqllder.
sqlldr userid=orcl/orcle control=".$controlfile." log=".$logfile.".log data=".$datafile." bad=".$badfile." discard=".$discardfile." Bindsize=19000000 Rows=100000 Readsize=20000000 Errors=1000000";
Thanks in advanceuser9256814 wrote:
Hi Team,
My database version is 11.1.0.7.0. I am loading the data using sqlldr. I am getting the error ORA-00060: deadlock detected while waiting for resource. once dead lock detected ,whether data will be rejected after commit point reached(Rows=100000). FYI information only sqllder is running on the database,it is getting completed withing 5-10min. please help me whether any other lock happening on this due to sqllder.
sqlldr userid=orcl/orcle control=".$controlfile." log=".$logfile.".log data=".$datafile." bad=".$badfile." discard=".$discardfile." Bindsize=19000000 Rows=100000 Readsize=20000000 Errors=1000000";
Thanks in advanceadditional clues will exist within alert_SID.ora file & subsequent trace file. -
ORA-00060 DEADLOCK DETECTED - Need Help
Hi Gurus,
I have a question on how to determine the trace log. Where the deadlock happen.
Please help. I have no other hint on how to resolve the error.
*** ACTION NAME:() 2008-08-06 03:34:21.740
*** MODULE NAME:(OEM.SystemPool) 2008-08-06 03:34:21.740
*** SERVICE NAME:(celcomdb) 2008-08-06 03:34:21.740
*** CLIENT ID:() 2008-08-06 03:34:21.740
*** SESSION ID:(113.3188) 2008-08-06 03:34:21.740
DEADLOCK DETECTED ( ORA-00060 )
[Transaction Deadlock]
The following deadlock is not an ORACLE error. It is a
deadlock due to user error in the design of an application
or from issuing incorrect ad-hoc SQL. The following
information may aid in determining the deadlock:
Deadlock graph:
---------Blocker(s)-------- ---------Waiter(s)---------
Resource Name process session holds waits process session holds waits
TM-0000c45a-00000000 119 113 X 27 60 SX
TX-0004002c-000269bc 27 60 X 119 113 X
session 113: DID 0001-0077-00000028 session 60: DID 0001-001B-00000278
session 60: DID 0001-001B-00000278 session 113: DID 0001-0077-00000028
Rows waited on:
Session 60: no row
Session 113: obj - rowid = 0000C384 - AAAMOEAADAAAF99AAA
(dictionary objn - 50052, file - 3, block - 24445, slot - 0)
Information on the OTHER waiting sessions:
Session 60:
pid=27 serial=1313 audsid=0 user: 51/SYSMAN
O/S info: user: oracle10, term: UNKNOWN, ospid: 14610456, machine: S63KLJ01
program: oracle@S63KLJ01 (J000)
application name: EM_PING, hash value=2147830874
action name: AGENT_STATUS_MARKER, hash value=2850782869
Current SQL information unavailable
End of information on OTHER waiting sessions.
Current SQL statement for this session:
UPDATE MGMT_OMS_PARAMETERS SET VALUE=TO_CHAR(SYSDATE, 'DD-Mon-YYYY HH24:MI:SS') WHERE HOST_URL=:B1 AND NAME='TIMESTAMP'
----- PL/SQL Call Stack -----
object line object
handle number name
70000006e5ab778 39 package body SYSMAN.MGMT_FAILOVER
70000002e8aaf98 1 anonymous block
===================================================
PROCESS STATE
Process global information:
process: 70000006f4b1598, call: 70000006a9c9320, xact: 70000006dedcf98, curses: 70000006f5a5a50, usrses: 70000006f5a5a50
SO: 70000006f4b1598, type: 2, owner: 0, flag: INIT/-/-/0x00
(process) Oracle pid=119, calls cur/top: 70000006a9c9320/70000006abfcaf8, flag: (0) -
int error: 0, call error: 0, sess error: 0, txn error 0
(post info) last post received: 0 0 9
last post received-location: ksqrcl
last process to post me: 70000006f484118 141 0
last post sent: 0 0 0
last post sent-location: No post
last process posted by me: none
(latch info) wait_event=0 bits=0
Process Group: DEFAULT, pseudo proc: 70000006f50bcd0
O/S info: user: oracle10, term: UNKNOWN, ospid: 11538508
OSD pid info: Unix process pid: 11538508, image: oraclecelcomdb@S63KLJ01
Dump of memory from 0x070000006F45FCD0 to 0x070000006F45FED8
70000006F45FCD0 00000004 00000000 07000000 6A9ABD00 [............j...]
70000006F45FCE0 00000010 0003139D 07000000 6ABFCAF8 [............j...]
70000006F45FCF0 00000003 0003139D 07000000 6F8FD600 [............o...]
70000006F45FD00 0000000B 0003139D 07000000 6F5A5A50 [............oZZP]
70000006F45FD10 00000004 00031291 00000000 00000000 [................]
70000006F45FD20 00000000 00000000 00000000 00000000 [................]
Repeat 26 times
70000006F45FED0 00000000 00000000 [........]
SO: 70000006f5a5a50, type: 4, owner: 70000006f4b1598, flag: INIT/-/-/0x00
(session) sid: 113 trans: 70000006dedcf98, creator: 70000006f4b1598, flag: (41) USR/- BSY/-/-/-/-/-
DID: 0001-0077-00000028, short-term DID: 0000-0000-00000000
txn branch: 0
oct: 6, prv: 0, sql: 70000006e5a9140, psql: 70000006e5a9410, user: 51/SYSMAN
O/S info: user: oracle10, term: unknown, ospid: 1234, machine: S63KLJ01
program: OMS
client info: S63KLJ01_Management_Service
application name: OEM.SystemPool, hash value=2960518376
last wait for 'enq: TX - row lock contention' blocking sess=0x70000006f5611e0 seq=322 wait_time=2929700 seconds since wait started=4
name|mode=54580006, usn<<16 | slot=4002c, sequence=269bc
Dumping Session Wait History
for 'enq: TX - row lock contention' count=1 wait_time=2929700
name|mode=54580006, usn<<16 | slot=4002c, sequence=269bc
for 'enq: TM - contention' count=1 wait_time=224489
name|mode=544d0006, object #=c45a, table/partition=0
for 'enq: TM - contention' count=1 wait_time=2929708
name|mode=544d0006, object #=c45a, table/partition=0
for 'SQL*Net message from client' count=1 wait_time=35033
driver id=28444553, #bytes=1, =0
for 'SQL*Net message to client' count=1 wait_time=1
driver id=28444553, #bytes=1, =0
for 'SQL*Net message from client' count=1 wait_time=227
driver id=28444553, #bytes=1, =0
for 'SQL*Net message to client' count=1 wait_time=1
driver id=28444553, #bytes=1, =0
for 'latch: library cache' count=1 wait_time=96826
address=70000006cf2f298, number=d6, tries=0
for 'latch: library cache' count=1 wait_time=36929
address=70000006cf2f0b8, number=d6, tries=0
for 'SQL*Net message from client' count=1 wait_time=131974
driver id=28444553, #bytes=1, =0
temporary object counter: 0
Virtual Thread:
kgskvt: 70000006e82cd98, sess: 70000006f5a5a50, vc: 0, proc: 70000006f4b1598
consumer group cur: OTHER_GROUPS (upd? 0), mapped: DEFAULT_CONSUMER_GROUP, orig:
vt_state: 0x200, vt_flags: 0x30, blkrun: 0
is_assigned: 1, in_sched: 0 (0)
vt_active: 0 (pending: 1)
used quanta: 0 (cg: 0)
cpu start time: 0, quantum status: 0x0
quantum checks to skip: 0, check thresh: 0
idle time: 0, active time: 0 (cg: 0)
cpu yields: 0 (cg: 0), waits: 0 (cg: 0), wait time: 0 (cg: 0)
queued time outs: 0, time: 0 (cur 0, cg 0)
calls aborted: 0, num est exec limit hit: 0
undo current: 0k max: 0k
UOL used : 0 locks(used=2, free=0)
KGX Atomic Operation Log 70000002eb54978
Mutex 0(0, 0) idn 0 oper NONE
Cursor Parent uid 113 efd 15 whr 22 slp 0
oper=NONE pt1=0 pt2=0 pt3=0
pt4=0 u41=0 stt=0
KGX Atomic Operation Log 70000002eb549c0
Mutex 0(0, 0) idn 0 oper NONE
Library Cache uid 113 efd 0 whr 0 slp 0
KGX Atomic Operation Log 70000002eb54a08
Mutex 0(0, 0) idn 0 oper NONE
Library Cache uid 113 efd 0 whr 0 slp 0
SO: 70000006ae53108, type: 53, owner: 70000006f5a5a50, flag: INIT/-/-/0x00
LIBRARY OBJECT LOCK: lock=70000006ae53108 handle=70000002e8e8150 mode=N
call pin=0 session pin=0 hpc=0000 hlc=0000
htl=70000006ae53188[70000006a753478,70000006abaf090] htb=70000006abaf090 ssga=70000006abae018
user=70000006f5a5a50 session=70000006f5a5a50 count=1 flags=CBK[0020] savepoint=0x0
LIBRARY OBJECT HANDLE: handle=70000002e8e8150 mtx=70000002e8e8280(0) cdp=0
namespace=CRSR flags=RON/KGHP/PN0/EXP/[10010100]
kkkk-dddd-llll=0000-0001-0001 lock=N pin=S latch#=4 hpc=0000 hlc=0000
lwt=70000002e8e81f8[70000002e8e81f8,70000002e8e81f8] ltm=70000002e8e8208[70000002e8e8208,70000002e8e8208]
pwt=70000002e8e81c0[70000002e8e81c0,70000002e8e81c0] ptm=70000002e8e81d0[70000002e8e81d0,70000002e8e81d0]
ref=70000002e8e8228[70000004ad30028,70000004ad30028] lnd=70000002e8e8240[70000002e8e8240,70000002e8e8240]
LIBRARY OBJECT: object=70000004ad2f990
type=CRSR flags=EXS[0001] pflags=[0000] status=VALD load=0
DEPENDENCIES: count=1 size=16
AUTHORIZATIONS: count=1 size=16 minimum entrysize=16
ACCESSES: count=1 size=16
TRANSLATIONS: count=1 size=16
DATA BLOCKS:
data# heap pointer status pins change whr
0 70000006eada130 70000004ad2faa8 I/P/A/-/- 0 NONE 00
6 70000004ad2fec8 700000040f57a78 I/P/A/-/E 0 NONE 00
----------------------------------------Oracle handles dead lock by its own. but to resolve the issue u can try following things.
1. take explain for UPDATE MGMT_OMS_PARAMETERS SET VALUE=TO_CHAR(SYSDATE, 'DD-Mon-YYYY HH24:MI:SS') WHERE HOST_URL=:B1 AND NAME='TIMESTAMP';
2. analyze above explain plan and try to tune it.
i think, its because of missing indexes. -
ORA-00060 "deadlock detected while waiting for resource"
Hello.
I am having an oracle deadlock when calling a stored procedure (wich updates several records in several tables) from several threads: ORA-00060 error. The error does not happen very often but from time to time, normally the calls to this proceudre end ok.
Each call starts and ends a transaction. (When the oracle error raises the transaction where it raises is rolled back) and the other transactions can go on.
I don't how to avoid it. Should it be solved at the stored procedure level or could it be solved at java level by doing the call to the stored procedure to be synchronized?
Thanks in advance.Fernando_Sanchez wrote:
Hello.
I am having an oracle deadlock when calling a stored procedure (wich updates several records in several tables) from several threads: ORA-00060 error. The error does not happen very often but from time to time, normally the calls to this proceudre end ok.Which doesn't really sound good.
If you have a java thread then to do JDBC, regardless of what type, you get a new connection and new statements in each one.
If you are not doing that then that is a problem.
If you are doing that then the thread information is irrelevant at the java level.
You can of course do all sorts of interesting things with locks and transactions in Oracle and via stored procs but other ways as well. And if you are not careful it will cause problems. -
CX_SY_OPEN_SQL_DB:ORA-00060: deadlock detected
Hi All,
I am runtime error DBIF_RSQL_SQL_ERROR abd Exception
CX_SY_OPEN_SQL_DB in the following code.
I am pasting Error Analysis from ST22.
An exception occurred. This exception is dealt with in more detail below
. The exception, which is assigned to the class 'CX_SY_OPEN_SQL_DB', was
neither
caught nor passed along using a RAISING clause, in the procedure "LOAD_ORDERSEQ"
"(FORM)"
Since the caller of the procedure could not have expected this exception
to occur, the running program was terminated.
The reason for the exception is:
<b>The database system recognized that your last operation on the database
would have led to a deadlock.
Therefore, your transaction was rolled back
to avoid this.</b>
ORACLE always terminates any transaction that would result in deadlock.
The other transactions involved in this potential deadlock
are not affected by the termination.
LOOP AT LT_ORDER INTO LS_ORDER.
SELECT SINGLE * FROM ZJD_ORDER
WHERE ORDER_ID = LS_ORDER-ORDER_ID.
IF SY-SUBRC NE 0.
LS_ORDER-ORDER_STATUS = 'O'.
INSERT ZJD_ORDER FROM LS_ORDER.
IF SY-SUBRC NE 0.
WRITE : / 'Error while inserting order sequence for ',
LS_ORDER-ORDER_ID.
ELSE.
ADD 1 TO GV_TREC_ORDER.
ENDIF.
ELSEIF ZJD_ORDER-OEDER_SEQUENCE > LS_ORDER-ORDER_SEQUENCE.
UPDATE ZJD_ORDER
SET ORDER_SEQUENCE = LS_ORDER-ORDER_SEQUENCE
WHERE ORDER_ID EQ LS_ORDER-ORDER_ID.
IF SY-SUBRC NE 0.
WRITE : / 'Error while updating order sequence for',
LS_ORDER-ORDER_ID.
ELSE.
ADD 1 TO GV_TREC_ORDER.
ENDIF.
ENDIF.
ENDLOOP.
one solution is to catch exception CX_SY_OPEN_SQL_DB in my program, but My query is how can I avoid this Deadlock
situation.
Thank You.
Regards,
JashanUPDATE ZJD_ORDER
SET ORDER_SEQUENCE = LS_ORDER-ORDER_SEQUENCE
WHERE ORDER_ID EQ LS_ORDER-ORDER_ID.
what are the keyfields in ZJD_ORDER table.
do you have more than one key field (i.e other than ORDER_ID)
and use commit work if sy-subrc = 0.
Regards
vijay
Maybe you are looking for
-
Hi Friends, I know that SMQ2 ia a inbound queue and SMQ1 is a outboud queue but wanted to know where this queues are present exactly and Purpose I guess SMQ2 is the first step in IE after AE forwards the PI SOAP Message and before the Pipeline steps.
-
Wow, this is annoying. Ever since upgrading to Lion I notice my spell-check is no longer just "checking" for me. It's pulling that same crapola that goes on in iOS where it just replaces words whether you want it to or not; usually to comic effect. P
-
I just purchased a new computer. How do I get my Adobe CS5 on my new system?
I have no disc, it was a download. Please help!
-
I have a 500GB backup of Elements 10 in one library. I'd like to switch from my Windows 8 PC to one of the new iMacs. Is there a process to do a restore on the Mac? Thanks for any guidance or link.
-
Has anyone tried using ODBC to an Excel workbook as the input for DTW? I have gotten the ODBC process to work from Access but I can't figure what is needed for the "simple SQL" when using Excel. Any thoughts will be greatly appreciated. Ross Unger