Can i enable RCP in DB2 API Stage

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
satishmelinamani
Participant
Posts: 7
Joined: Wed Jun 28, 2006 1:36 am
Location: Bangalore

Can i enable RCP in DB2 API Stage

Post by satishmelinamani »

Hi,

Is there any way that i can enable Runtime Column Propogation(RCP) in DB2 API Stage. My requirement is to have a generic job which can extract data from DB2 database without actually defining the column metadata.

Thanks,
Satish
Daddy Doma
Premium Member
Premium Member
Posts: 62
Joined: Tue Jun 14, 2005 7:17 pm
Location: Australia
Contact:

Post by Daddy Doma »

I'm trying to test this same issue right now, and I suspect the answer is no. It works fine using the EE stage, but returns the following error when running use API:

Code: Select all

Fatal Error: Fatal: This SQL statement did not contain the same number of parameters as columns on this link.  This usually happens with user-defined SQL.
When you know that you are destined for greatness by virtue of your mutant heritage it is difficult to apply yourself to normal life. Why waste the effort when you know that your potential is so tremendous?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Theoretically the answer is yes. With RCP enabled, the default behaviour of Read mode is the same as SELECT * FROM tablename; - that is, all columns are selected. In practice this can result in far more data having to be transferred from the database server to DataStage than is really warranted.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Daddy Doma
Premium Member
Premium Member
Posts: 62
Joined: Tue Jun 14, 2005 7:17 pm
Location: Australia
Contact:

Post by Daddy Doma »

I agree with your comments about RCP, Ray. In practice we are trying to limit it's application to jobs where the same processes need to be ran over and over and over again (i.e. thousands of files to be processed and loaded to a database).

The error I described above occurs when trying to load a database table via the API stage. Our situation is:

- We have numerous sequential files of different formats, that are constantly changing.
- We want to do a simple one-to-one load from file into a database table.
- Ideally, we would like to drop the table, create a new one using the RCP, and load.

Now, the API stage drops the table correctly, but does not pass the RCP to the Create Table DDL. We decided to compromise by manually changing the tables whenever the input file is different, but the API stage still does not allow us to insert records using RCP.

This all works when using the EE stage, but our database admin/security team does not want to set up the target database to support this.
When you know that you are destined for greatness by virtue of your mutant heritage it is difficult to apply yourself to normal life. Why waste the effort when you know that your potential is so tremendous?
tagnihotri
Participant
Posts: 83
Joined: Sat Oct 28, 2006 6:25 am

Post by tagnihotri »

I have tried otherway round i.e. to load data using dataset and seq files and it works fine for me!!

Do remmember you have to make sure the target if not the source should be able to pick up the metadata and then it should work fine.

ray.wurlod wrote:Theoretically the answer is yes. With RCP enabled, the default behaviour of Read mode is the same as SELECT * FROM tablename; - that is, all columns are selected. In practice this can result in far ...
Post Reply