Transformer concatenate

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
suryadev
Premium Member
Premium Member
Posts: 211
Joined: Sun Jul 11, 2010 7:39 pm

Transformer concatenate

Post by suryadev »

While using concatenate in transformer,

first create a field...by any NAME in the columns in the bottom of properties of transformer

and then...in the output field use..the empty space on the left of the new field.
in that..empty space called derivation.right click and select a column and concatenate and then again column again concatenate...

it goes like-->dslink.first_nm:dslink.middle_nm:dslink.last_nm:concatenate
is this the right way to use concatenate...and length....also.add all the three fields lengths and that will be the length of the new field....NAME

Please let me know if I need to change anything...because...

the ouput which I am getting right now...is not in an order....and I am missing some text in that...output...
Thanks,
Surya
anbu
Premium Member
Premium Member
Posts: 596
Joined: Sat Feb 18, 2006 2:25 am
Location: india

Post by anbu »

You should get the order you have it in your derivation.

Add derivation separately for all the columns included in your concatenation and verify you have values in all the fields
You are the creator of your destiny - Swami Vivekananda
arun_im4u
Premium Member
Premium Member
Posts: 104
Joined: Mon Nov 08, 2004 8:42 am

Post by arun_im4u »

If any of your three fields are NULL then your output is going to be NULL, bcause concatenation with NULL will result in a NULL.

You will get the same length in the output only if your are concatenating CHAR fields. If you are concatenating varchar type fields then the length might differ.

If the above are true you should be getting the right results.

There is a concatenate at the end of your derivation. Is that a typo?

dslink.first_nm:dslink.middle_nm:dslink.last_nm[b]:concatenate[/b]
suryadev
Premium Member
Premium Member
Posts: 211
Joined: Sun Jul 11, 2010 7:39 pm

Post by suryadev »

There are 4 fields and I want them to be as a single field so I used concatenate only to my new Field derivation because that is the only field available...now in the output
and I did not use any constraint in the transformer as I used concatenate in my New single field.
Thanks,
Surya
Post Reply