Runtime Column Propagation and inserting into DB

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
Cranie
Premium Member
Premium Member
Posts: 19
Joined: Fri Mar 03, 2006 6:02 pm
Location: Sheffield

Runtime Column Propagation and inserting into DB

Post by Cranie »

Hi,

Its been a long time since I have developed in DS (usually admin only).

I am trying to write the following job:

Teradata1 -> sort1 -> Copy1 -> merge
then
Teradata2 -> sort2 -> Copy2 -> merge

From the merge (same stage) I have two output links, one for good records, one for bad as following:

Merge -> Teradata3
L - -> Teradata4

What I have in the Teradata3 and 4 stages SQL is:

Code: Select all

INSERT INTO #pTDRESDB#.#pTDRESTABLE#
(DBName, TBName, CompareResult, DataDate, RowCount
VALUES ('#pTDSRCDATABASE#','#pTDSRCTABLE#','OK',?,?)
Where I want ? and ? to be the columns that are generated via the runtime column propagation. Obviously this is failing:
Teradata_Connector_81: Unable to determine association between statement parameters and table columns. The connector will not be able to obtain external schema and only limited schema reconciliation will be performed
Is there any way I can achieve this (in the one job) without writing a separate load job?

Thanks.
- - - - -

Cranie

Doing the needful.
BI-RMA
Premium Member
Premium Member
Posts: 463
Joined: Sun Nov 01, 2009 3:55 pm
Location: Hamburg

Re: Runtime Column Propagation and inserting into DB

Post by BI-RMA »

Hi Cranie,

What You are doing seems rather strange to me. Runtime Column propagation assumes that you do not necessarily know the columns contained in the flow at runtime.

Your SQL-Statement, however, knows precisely, of which columns your target-table consists. Are you sure that your data-flow does not try to send more columns down the stream than you expect? Check this by using a peek-stage or - if possible -by creating the target-table.
"It is not the lucky ones are grateful.
There are the grateful those are happy." Francis Bacon
Cranie
Premium Member
Premium Member
Posts: 19
Joined: Fri Mar 03, 2006 6:02 pm
Location: Sheffield

Post by Cranie »

Think you are right.. Think I have over complicated this.. lol.

Its the next job (comparing all columns). which I will need to do something similar. I'm going to close this topic and hang my head in shame.
- - - - -

Cranie

Doing the needful.
Post Reply