Hi,
As the beautifier is still new, I thought you guys might want to know that it doesn't want to format merge statements. E.g. the following leads to a "could not parse text" message. NOTE: When this happens, I'm only beautifying the MERGE, the additional code is just for clarity.
------------------
Hakuna Matata,
Arnoud.
[This message has been edited by aotte (edited 07 May 2003).]
As the beautifier is still new, I thought you guys might want to know that it doesn't want to format merge statements. E.g. the following leads to a "could not parse text" message. NOTE: When this happens, I'm only beautifying the MERGE, the additional code is just for clarity.
Code:CREATE TABLE trgt ( col1 NUMBER, col2 NUMBER); CREATE TABLE src ( col1 NUMBER, col2 NUMBER); INSERT INTO trgt VALUES (1,1); INSERT INTO src VALUES (1,2); INSERT INTO src VALUES (2,3); COMMIT; ---8<--- MERGE INTO trgt t USING (SELECT col1, col2 FROM src) s ON (s.col1 = t.col1) WHEN MATCHED THEN UPDATE SET t.col2 = s.col2 WHEN NOT MATCHED THEN INSERT ( col1, col2) VALUES ( s.col1, s.col2); ---8<--- SELECT * FROM trgt;
------------------
Hakuna Matata,
Arnoud.
[This message has been edited by aotte (edited 07 May 2003).]