Complex SQL-ish Join

D

Dan McCollick

Hello,
I currently have 2 arrays of a class setup like this:
Unit, Month, Amt
ex
The Accrual Array has
Unit 1, Jan, 1000
Unit 1, Feb, 50000
Unit 2, Feb, 100

The Paid Array has
Unit 1, Feb 1000

Is there a simple way to join(on Unit in this case, but possibly by
multiple fields) this data to end up with

Unit, Month, Amt, Month, Amt
ex.
Unit 1, Jan, 1000, ,
Unit 1, Feb, 50000, Feb, 1000
Unit 2, Feb, 100, ,

I would rather not have to reiterate through each array element by
element. I was wondering if there was a "Join" function like in sql,
or something of that nature.

Thank you
Dan McCollick
 
Top