Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Data Bases > Oracle Server > Complex Structu...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 3 Topic 16456 of 16958
Post > Topic >>

Complex Structures within PL/SQL

by Le Tubs <dlaw001@[EMAIL PROTECTED] > Apr 23, 2008 at 09:31 AM

Hi

Apologies if this gets posted twice

I am relatively new to PL/SQL and want to do is find a list of
duplicate records, then recording the duplicate c_rec id's in some
sort of structure which I can extract at a later date
this is what I have got so far ....

TYPE DupID as Table of (

	wID NUMBER;
	AID NUMBER;
	BID Number;
)

select ???? = A.PAYROLL_ID, A.C_REC, B.C_REC from FMAPPING A where
		(SELECT * FROM FMAPPING B where
			A.PAYROLL_ID = B.PAYROLL_ID AND A.C_REC <> B.C_REC);

-- at this point can just extract each row, and I will have access to
the payroll_id, and the unique c_rec


So is this correct, but how do I load the DupID table with the
contents of the select statment (I am assuming that the sql is
correct)

I would ideally like to learn what I'm doing right and wrong, so
ideally what I'm after are pointers to reference sites, decent example
sites or books rather than just the answer. Any tips or pointers ectra
will be greatly appreciated.

Thanking you in advance for your time and consideration.


LeTubs
 




 3 Posts in Topic:
Complex Structures within PL/SQL
Le Tubs <dlaw001@[EMAI  2008-04-23 09:31:53 
Re: Complex Structures within PL/SQL
"Vladimir M. Zakhary  2008-04-23 11:12:42 
Re: Complex Structures within PL/SQL
joel garry <joel-garry  2008-04-23 11:25:43 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan13V112 Thu Jul 24 2:12:02 CDT 2008.