Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Problem With Merge Statement

Re: Problem With Merge Statement

From: <pankaj_wolfhunter_at_yahoo.co.in>
Date: 6 Apr 2006 05:08:24 -0700
Message-ID: <1144325304.699313.300070@g10g2000cwb.googlegroups.com>


Ok I got it. To be more frank this is my first test with MERGE statement. I used it as follows:

MERGE INTO ext_category t_dest
USING ( SELECT * FROM category) t_src
ON (t_dest.name = t_src.name)
WHEN MATCHED THEN
        UPDATE SET t_dest.exp_date=t_src.exp_date, t_dest.exp_time=t_src.exp_time WHERE t_dest.exp_date IS NULL and t_dest.exp_time IS NULL
WHEN NOT MATCHED THEN

        INSERT(name, exp_date, exp_time, flg)
            VALUES(t_src.name, t_src.exp_date, t_exp_time, t_src.flg);

Thanks for the help, but now I am getting an error as ORA-30926: unable to get a stable set of rows in the source tables

Any ideas? Received on Thu Apr 06 2006 - 07:08:24 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US