Skip to Content
0
Former Member
Oct 19, 2006 at 08:17 PM

Update Rules

11 Views

I am loading ODS1 from a file that contains employee check deduction data. ODS1 also needs to contain employee relevant data (name, department, etc) that is stored in ODS2.

Example:

ODS1 has Employee Number, deduction type, Deduction amount.

<b>Empl Dedtype Dedamt</b>

EMP1 // DED1 // $100

EMP1 // DED2 // $200

EMP1 // DED3 // $300

EMP2 // DED1 // $100

EMP2 // DED3 // $100

ODS2 contains employee number, department and about 25 other fields that are needed by ODS1

<b>Empl Name Depart. </b>

EMP1 // Name1 // Dept100

EMP2 // Name2 // Dept200

The end result should be populated as below:

<b>Empl Dedtype Dedamt Name Depart.</b>

EMP1 // DED1 // $100 // Name1 // Dept100

EMP1 // DED2 // $200 // Name1 // Dept100

EMP1 // DED3 // $300 // Name1 // Dept100

EMP2 // DED1 // $100 // Name2 // Dept200

EMP2 // DED3 // $100 // Name2 // Dept200

I am using update rules in ODS1 to get the data from ODS2. I have an update rule for each of the 25 fields from ODS2. In order to populate one record in ODS1, ODS2 must be read 25 times for each of the 25 fields and their associated update rules. Is there a way to read the ODS2 record one time and update all the fields in ODS1 record? Maybe some kind of internal table? How would this be coded?

Thanks in advance,

Vicki