Home » SQL & PL/SQL » SQL & PL/SQL » ORA-30926: unable to get a stable set of rows in the source tables (oracle 10g)
ORA-30926: unable to get a stable set of rows in the source tables [message #395273] Wed, 01 April 2009 00:14 Go to next message
ora_2007
Messages: 430
Registered: July 2007
Location: Mumbai
Senior Member
Please tell me how i can resolve this error.
SQL> MERGE INTO test.MINT c
  2  USING scott.MINT_UNI2 e
  3  ON (c.ID = e.ID)
WHEN MATCHED THEN
  4    5  UPDATE SET
  6  c.DATABASE_ID     =     e.DATABASE_ID     ,
  7  c.MINTNO    =     e.MINTNO    ,
  8  c.FIRSTNAME       =     e.FIRSTNAME       ,
  9  c.LASTNAME  =     e.LASTNAME  ,
 10  c.TITLE     =     e.TITLE     ,
 11  c.SALUTATION      =     e.SALUTATION      ,
 12  c.ADDRESS1  =     e.ADDRESS1  ,
 13  c.ADDRESS2  =     e.ADDRESS2  ,
 14  c.ADDRESS3  =     e.ADDRESS3  ,
 15  c.POSTAL    =     e.POSTAL    ,
 16  c.CITY            =     e.CITY      ,
c.STATE     =     e.STATE     ,
 17   18  c.COUNTRY   =     e.COUNTRY   ,
 19  c.PHONE1    =     e.PHONE1    ,
 20  c.PHONE2    =     e.PHONE2    ,
c.EMAIL     =     e.EMAIL     ,
 21   22  c.COMPANY   =     e.COMPANY   ,
c.FAX             =     e.FAX       ,
 23   24  c.CUSTOM1   =     e.CUSTOM1   ,
 25  c.CUSTOM2   =     e.CUSTOM2   ,
 26  c.CUSTOM3   =     e.CUSTOM3   ,
 27  c.WANTSOUT  =     e.WANTSOUT  ,
 28  c.FAILED    =     e.FAILED    ,
 29  c.SYSCREATED      =     e.SYSCREATED      ,
 30  c.OPENED    =     e.OPENED    ,
 31  c.BOUNCE_MSG_T    =     e.BOUNCE_MSG_T
WHEN NOT MATCHED THEN
 32   33  INSERT VALUES(e.ID, e.DATABASE_ID,    e.MINTNO,               e.FIRSTNAME,    e.LASTNAME,     e.TITLE,        e.SALUTATION,   e.ADDRESS1, e.ADDRESS2, e.ADDRESS3,
 34                                     e.POSTAL,               e.CITY,                 e.STATE,                e.COUNTRY,              e.PHONE1,       e.PHONE2,            e.EMAIL, e.COMPANY, e.FAX,
 35                                     e.CUSTOM1,              e.CUSTOM2, e.CUSTOM3,                   e.WANTSOUT,     e.PERSONALMESSAGE, e.PERSONALSALESREP, e.SYSCREATED,
 36                                     e.SYSCHANGED,   e.SYSCREATEDBY, e.SYSCHANGEDBY, e.LOGONCOUNT,   e.FIRSTLOGON,      e.LASTLOGON, e.PASSWORD, e.CALLED,
 37                                     e.NEXTCALL,     e.CALLEDBY, e.TESTMINT, e.REGISTERED,                   e.HARDRESPONCECOUNT,                       e.RESPONCEIP,
 38                                     e.FAILED, e.GLOBAL_ID,  e.OPENED,               e.BOUNCE_MSG_T);

            MERGE INTO test.MINT c
*
ERROR at line 1:
ORA-30926: unable to get a stable set of rows in the source tables


Elapsed: 00:12:44.11
Re: ORA-30926: unable to get a stable set of rows in the source tables [message #395274 is a reply to message #395273] Wed, 01 April 2009 00:16 Go to previous messageGo to next message
BlackSwan
Messages: 25050
Registered: January 2009
Location: SoCal
Senior Member
Provide us DDL & DML to obtain reproducible test case.
Re: ORA-30926: unable to get a stable set of rows in the source tables [message #395275 is a reply to message #395274] Wed, 01 April 2009 00:20 Go to previous messageGo to next message
bonker
Messages: 402
Registered: July 2005
Senior Member
You must be having duplicate ID's in scott.MINT_UNI2 table and therefore getting this error.

[Updated] Corrected small spelling mistake in the message

[Updated on: Wed, 01 April 2009 00:22]

Report message to a moderator

Re: ORA-30926: unable to get a stable set of rows in the source tables [message #395285 is a reply to message #395273] Wed, 01 April 2009 01:10 Go to previous message
ora_2007
Messages: 430
Registered: July 2007
Location: Mumbai
Senior Member
Thanks a lott.
This table was having duplicate recordds. scott.MINT_UNI2

So i deleted duplicates and it works.

Thanks,
Previous Topic: Instead of Connect by prior
Next Topic: Group By clause and sum(sal) (2 threads merged by bb)
Goto Forum:
  


Current Time: Fri Dec 09 17:07:57 CST 2016

Total time taken to generate the page: 0.10718 seconds