Skip to Content

How to concatenate two Info objects in Transformations with space in between

Hi Guys,

I need to concatenate two objects (0CUSTOMER and 0MATERIAL) in transformations. I tried

CONCATENATE SOURCE_FIELDS-CUSTOMER SOURCE_FIELDS-MATERIAL INTO RESULT.

But the space is still not coming between the two. I did research on SCN and found a link but that is not resolved.

Concatenate 2 characteristics with a space | SC

Can someone please help me?

Regards

Prashant

Add a comment
10|10000 characters needed characters exceeded

Related questions

4 Answers

  • Best Answer
    Posted on Dec 07, 2015 at 02:02 PM

    Hi Prashant

    The code mentioned by Suhas defenitely works.

    I tried all of the above and the below code works for sure. I have even given an example.

    Below is the code part

    DATA: temp type c length 10. " give the length of your result field

    CONCATENATE source_fields-comp_code ` ` source_fields-distr_chan INTO

    temp.

    RESULT = temp.

    Test in transformation with a sample data.

    Please check his point to use ` ` instead of ' '.

    Hope this helps

    Regards

    Karthik


    Capture.PNG (7.6 kB)
    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Dec 07, 2015 at 03:35 AM

    Yes, concatenate behaves inconsistently with space.

    You can solve this by using the backquotes (the ` character, which is just above the TAB key on many keyboards) to delimit the space. So the command becomes

    CONCATENATE SOURCE_FIELDS-CUSTOMER ` ` SOURCE_FIELDS-MATERIAL INTO RESULT.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 07, 2015 at 02:04 PM

    you can write a end routine

    loop at result_package assigning <result_fields>.

    concatenate <result_fields>-/bic/fileldname1 <result_fields>-/bic/fieldname2 into <result_fields>-/bic/fieldname

    endloop.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Dec 08, 2015 at 10:36 AM

    still not resolved?

    paste the code which you have written once. code given by suhas must works.

    regards,

    anil

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.