Linking Other Tables

Formally known as "Mercator Inside Integrator 6.7", DataStage TX enables high-volume, complex transactions without the need for additional coding.

Moderators: chulett, rschirm

Post Reply
phillip.small
Participant
Posts: 29
Joined: Mon Aug 16, 2004 8:12 am

Linking Other Tables

Post by phillip.small »

I'm hoping someone can help me. I'm having a simple developer issue on trying to get one field to populate in the target table.
Basically, I'm loading a flat file to a target table, but want to grab one more field(which is a key field in the target table) for the target. The input file has 6 primary keys and is not going to the join link stage because that object does not have the position nbr column.

In DB2 SQL, that query looks like this:

select a.position_nbr
from taads_stg_hash(hash file) a, taads_rmks(sequential file) b
where a.deptid = b.uic_cd
and a.effdt = b.effdt

taads_stg_hash has:

position_nbr
deptid
effdt

taads_rmks seq file has:

deptid
effdt
Rank
location
end_effdt

The target table looks like:

position_nbr
deptid
effdt
rank
location
end_effdt

I'm having trouble getting the position_nbr from a hash file(or table) to load into the target table where the deptid and effdt match.

Some questions. Should I use a hash file? How do I get the the Position Nbr to populate?
Attached in this note is a zip file of the Ascential Job and the Tranformer. I'm not sure if I'm doing it correctly or I don't know what I'm missing. It seems simple to do, but I can't seem to get it to work via DataStage. Let me know if you need clarification. I don't know if I explained it very well. Thanks! I have the print screens to better show this if that would help. My email address is phillip.t.small@hoffman.army.mil.

Thanks for your help,
Phil
Post Reply