File tree Expand file tree Collapse file tree 2 files changed +5
-8
lines changed Expand file tree Collapse file tree 2 files changed +5
-8
lines changed Original file line number Diff line number Diff line change 402402 and a unique index is present and a duplicate row is concurrently
403403 inserted, then a uniqueness violation error is raised;
404404 <command>MERGE</command> does not attempt to avoid such
405- errors by evaluating <literal>MATCHED</literal> conditions.
405+ errors by restarting evaluation of <literal>MATCHED</literal>
406+ conditions.
406407 </para>
407408
408409 <para>
Original file line number Diff line number Diff line change @@ -266,10 +266,6 @@ DELETE
266266 filled with a default value, either its declared default value
267267 or null if there is none.
268268 </para>
269- <para>
270- If the expression for any column is not of the correct data type,
271- automatic type conversion will be attempted.
272- </para>
273269 <para>
274270 If <replaceable class="parameter">target_table_name</replaceable>
275271 is a partitioned table, each row is routed to the appropriate partition
@@ -581,12 +577,12 @@ WHEN NOT MATCHED THEN
581577<programlisting>
582578MERGE INTO CustomerAccount CA
583579USING (Select CustomerId, TransactionValue From RecentTransactions) AS T
584- ON CA.CustomerId = T.CustomerId
580+ ON T.CustomerId = CA.CustomerId
581+ WHEN MATCHED THEN
582+ UPDATE SET Balance = Balance + TransactionValue;
585583WHEN NOT MATCHED THEN
586584 INSERT (CustomerId, Balance)
587585 VALUES (T.CustomerId, T.TransactionValue)
588- WHEN MATCHED THEN
589- UPDATE SET Balance = Balance + TransactionValue;
590586</programlisting>
591587 </para>
592588
You can’t perform that action at this time.
0 commit comments