Data Set File

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
somu_june
Premium Member
Premium Member
Posts: 439
Joined: Wed Sep 14, 2005 9:28 am
Location: 36p,reading road

Data Set File

Post by somu_june »

Hi,

Please help me and correct me if Iam wrong. I have columm like Reckey and OutRec comming from two transformers output and Iam writting to two datasets. Iam mentioning Reckey as key sqltype char and length '1' and nullable not. where for OutRec Iam not giving as key and sqltype varchar and length 80 and nullable yes. While compiling Iam getting an error as Duplicate field Identifier. I changed the columm names as OutRecI and OutRecD in datasets its working. But I want the same columm name in both datasets as OutRec . What I have to do for this .If have same columm name OutRec I can use funnel stage and I can write output to a single dataset




Thanks,
somaraju
somaraju
aramachandra
Participant
Posts: 55
Joined: Tue Sep 20, 2005 10:58 am

Post by aramachandra »

I would think, that
With your nullable=yes for one and nullable=no for the other, if the column names are same going through funnel stage you would still get an error at run time if the compile goes through.

Arvind
kumar_s
Charter Member
Charter Member
Posts: 5245
Joined: Thu Jun 16, 2005 11:00 pm

Post by kumar_s »

If i understand your issue properly, two link as output from transformer as identical name. This shouldnt be an issue. Can you post the exact error message you get. It will be more easy to identify the route cause.
Is RCP turned on?

-Kumar
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

I don't think this is possible without introducing some boundary, such as a Modify stage, to rename one (or both) of the distinct names back to the single name you require is separate Data Sets. Duplication of column names on outputs of Transformers appears not to be permitted.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
somu_june
Premium Member
Premium Member
Posts: 439
Joined: Wed Sep 14, 2005 9:28 am
Location: 36p,reading road

Post by somu_june »

Hi Kumar,

Please correct me if Iam wrong. Actually my requirement is to write two datasets in to a single dataset using funnel stage. I have first daaset with Reckey and OutRecI columms and second dataset with Reckey and OutRecD columms with same metadata. I have 1 .transformer.......... Rmvdup...................dataset

columm.........key.........sql........................null

Reckey......... key......... (char1)............No
OutRecI......... notkey....varchar(80)..... yes

from transformer1 to dataset1. Iam having same metadata


2. transforme ............ rmvdup...........................dataset

columm............ Key...............sql..................null
Reckey ............ key ...............(char1)..........NO
OutRecD...........notkey............ (varchar80)....yes

from transformer2 to dataset2. Iam having same metadata.

My requirement is to have the two datasets with same columm name that is instead of OutRecI and OutRecD. I want to have OutRec in both datasets. Or is there a way other than funnel stage to write these two datasets with different columms in to a single dataset.


Thanks,
Somaraju
somaraju
kumar_s
Charter Member
Charter Member
Posts: 5245
Joined: Thu Jun 16, 2005 11:00 pm

Post by kumar_s »

Let me assume the name of the links are identical. The name of the column in one link can be repeated in other link.
Yet to post the exact error message you got.

-Kumar
ameyvaidya
Charter Member
Charter Member
Posts: 166
Joined: Wed Mar 16, 2005 6:52 am
Location: Mumbai, India

Post by ameyvaidya »

Try this:
Keep the Metadata of all output columns from both transformers the same:
OutRecI->OutRec
OutRecD->OutRec

I assume that RCP is on.

Code: Select all

       (RCP Off)
Trans1----------|
                |
                Funnel-------> RemDuplicates----->Dataset
       (RCP Off)|
Trans2----------|
or if duplicates are to be removed from each link seperately:

Code: Select all

                           (RCP Off)
Trans1-------> RemDuplicates--------|
                                    |
                                    Funnel------>Dataset
                           (RCP Off)|
Trans2-------> RemDuplicates--------|

Amey Vaidya<i>
I am rarely happier than when spending an entire day programming my computer to perform automatically a task that it would otherwise take me a good ten seconds to do by hand.</i>
<i>- Douglas Adams</i>
somu_june
Premium Member
Premium Member
Posts: 439
Joined: Wed Sep 14, 2005 9:28 am
Location: 36p,reading road

Post by somu_june »

Hi Kumar,

The names of the links from two transformers are not identical.It shows an error like this


main_program: Fatal Error: Interface component "OutRec" is not a value field.




Thanks,
Somaraju
somaraju
somu_june
Premium Member
Premium Member
Posts: 439
Joined: Wed Sep 14, 2005 9:28 am
Location: 36p,reading road

Post by somu_june »

Hi Amey Vaidya,


Actually I tried uor optioin

Transformer1.............................................RmVdup1
output columm from Transform1.....Reckey,OutRecI

Transformer2................................................RmVdup2
output columm from transform2......Reckey,OutRecD


RmVdup1....(RCPOFF).................................DataSet1
output columm from RmVdup1.....Reckey,OutRec
RmVdup2.....(RCPOFF)................................DataSet2
OutPutColumm from RmVdup2.....Reckey,OutRec

But Iam getting the same error

main_program: Fatal Error: Interface component "OutRec" is not a value field.


Thanks,
Somaraju
somaraju
Post Reply