Patch Reviews - DB (MOSC)

MOSC Banner

oracle 19c merge into a view when not match ORA-07445, ORA-03113, ORA-03114

edited Sep 11, 2023 7:28PM in Patch Reviews - DB (MOSC) 2 commentsAnswered

Platform: Windows Server 2019

Product Name: Oracle 19c 19.3

Current Version: 19c 19.20 WinBP

OJVM: 19c 19.20

----------

Background:

On Windows, I cannot install patch 35182029 and OJVM 19.20 at the same time, they seem conflict with each other.

so I tried to repeat the problem MERGE INTO and found the following error

----------

To repeat the problem:

  1. Create a temp table
  2. Insert one row
  3. Do the merge into statement
  4. Error ora-07445, ORA-03113, ORA-0314

Detail Steps:

CREATE TABLE TestTable
(
 ID VARCHAR2(10),
 DESC1 VARCHAR2(10),
 DESC2 VARCHAR2(10),
 PRIMARY KEY (ID)
);

INSERT INTO TestTable(ID, DESC1, DESC2) VALUES ('X1', 'DESC1', 'DESC2');
COMMIT;

-- Test Error E1
MERGE INTO 
  (SELECT ID, DESC1, 'D2' AS DESC2 FROM TestTable WHERE ID = 'X1') t1
USING (SELECT 'X1' AS ID FROM dual) t2 ON (t1.ID = t2.ID)
WHEN MATCHED THEN
  UPDATE SET t1.DESC2 = 'D1';

-- Test Error E2
MERGE INTO 
  (SELECT ID, DESC1, 'D2' AS DESC2 FROM TestTable WHERE ID = 'X1') t1
USING (SELECT 'X2' AS ID FROM dual) t2 ON (t1.ID = t2.ID)
WHEN MATCHED THEN
  UPDATE SET t1.DESC2 = 'D1'
WHEN NOT MATCHED THEN
  INSERT (ID, DESC1, DESC2) VALUES ('X2', 'X2D1', 'X2D2')
;

-- Test Error E3
MERGE
Tagged:

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center