Link to home
Start Free TrialLog in
Avatar of d27m11y d27m11y
d27m11y d27m11yFlag for United States of America

asked on

FORALL in Oracle



I have the following sample data and I just want to swap only the membereligids for the same fname,lname and dob
keeping the rest of the data as it is. The issue is there is unique constraint on the column Membereligids.

Please see the attached sample data

I am not sure how I can develop logic using CURSORS/FORALL. Can someone guide me ?

Eg: Fname - Amit
 Lname - Kumar
  has two records with the same DOB but with different membereligids. I want to swap only 40681910,40813962

Sample-data.xls
Avatar of awking00
awking00
Flag of United States of America image

Are they always just duplicates or can there also be triplicates, for example?
ASKER CERTIFIED SOLUTION
Avatar of Swadhin Ray
Swadhin Ray
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of d27m11y d27m11y

ASKER

helpful!