Christopher Kings-Lynne wrote:
>
>*sigh* It's just like a standard to come up with a totally new syntax for a
>feature that no-one has except MySQL who use a different syntax :)
You sure? :)
http://otn.oracle.com/products/oracle9i/daily/Aug24.html
MERGE INTO SALES_FACT D USING SALES_JUL01 S ON (D.TIME_ID = S.TIME_ID AND D.STORE_ID = S.STORE_ID AND
D.REGION_ID= S.REGION_ID) WHEN MATCHED THEN UPDATE SET d_parts = d_parts + s_parts, d_sales_amt =
d_sales_amt+ s_sales_amt, d_tax_amt = d_tax_amt + s_tax_amt, d_discount = d_discount + s_discount
WHENNOT MATCHED THEN INSERT (D.TIME_ID ,D.STORE_ID ,D.REGION_ID, D.PARTS ,D.SALES_AMT ,D.TAX_AMT ,D.DISCOUNT)
VALUES ( S.TIME_ID ,S.STORE_ID ,S.REGION_ID, S.PARTS ,S.SALES_AMT ,S.TAX_AMT ,S.DISCOUNT);
For those who last played with 8X, they have a couple of other
new features in 9i. This is the best doc I saw talking about them.
http://www.oracle-base.com/Articles/9i/SQLNewFeatures9i.asp