dataload from multiple tables, there is no join condition

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
Sandeepch19
Participant
Posts: 36
Joined: Fri May 21, 2010 12:40 am
Location: Bangalore

dataload from multiple tables, there is no join condition

Post by Sandeepch19 »

We have to load data from multiple tables(oracle is the db) but there is no join condition between these tables. Let me give you an example

I have 5 columns that needs to loaded into a target table. But the first column (col1) does not have any join conditions between other 4 columns, col2 also does not have a any join condition with other three. But rest columns can be joined(col3,col4,col5). How can the data be loaded. Please advice.

FYI: We are using DS 8.7.UNIX(OS), Oracle(DB)
Sandeep Chandrashekar
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Where is the specification of what has to be loaded into each target column from each source (the "source to target mapping" document)?

If there is no common column Join would appear to be out of the question unless some kind of common column can be generated.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Sandeepch19
Participant
Posts: 36
Joined: Fri May 21, 2010 12:40 am
Location: Bangalore

Post by Sandeepch19 »

Target columns to be populated in given in the requirement document. As i said earlier first two columns does not have any join with other three. To make it clear. logic goes like this
source Col1- query table A - load into target col1
source Col2-query table B-load into target col2
source Col3-Query table C-load into target col3
source Col4-Query table D(which has join condition with C)- load into target col4
source Col5-Query table E(which has join condition with D)-load into target col5
Sandeep Chandrashekar
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Clear? Go back to whomever produced that specification and ask them how that is supposed to work. Without the join rules documented it is pretty much useless. All you know at this point is (I assume) what D & E records go in the table with a C record. But A & B? Who the heck knows? No-one on this side of the glass.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Sandeepch19
Participant
Posts: 36
Joined: Fri May 21, 2010 12:40 am
Location: Bangalore

Post by Sandeepch19 »

Craig,
yes, always we can go back to System Engineer on this requirement. But let me tell you the same kind of requirement was implemented using Java. There variables was used to store this col1 and col2 values( let me clarify here this col1 and col2 value will be same for that particular load) and this variables were passed into sql queries whil loading the data. Can we do along the same lines using datastage.
Sandeep Chandrashekar
priyadarshikunal
Premium Member
Premium Member
Posts: 1735
Joined: Thu Mar 01, 2007 5:44 am
Location: Troy, MI

Post by priyadarshikunal »

I would say no unless we know the exact logic of Java program.
Priyadarshi Kunal

Genius may have its limitations, but stupidity is not thus handicapped. :wink:
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Sandeepch19 wrote:(let me clarify here this col1 and col2 value will be same for that particular load)
Should have clarified that right away. It's an important piece of information.
Sandeepch19 also wrote:and this variables were passed into sql queries whil loading the data. Can we do along the same lines using datastage.
Of course, that's what job parameters are for. Or if your queries from the first two tables result in a single value, simply include them in the source SQL.

All Ray and I have been saying was you needed the rules defined for the relationship between these five tables, the rest is cake.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply