Skip to Content
author's profile photo Former Member
Former Member

how to prevent trimming when concatenating strings.

Hi, this is a question on concatenation.

DATA: TXT_FILENUMBER(3) TYPE C.

...

CONCATENATE 'AREA A FILE PATH ' TXT_FILENUMBER ' IS A REQUIRED FIELD.' INTO MAND_ERR_MSG.

...

The output of this concatenation is (assuming txt_filenumber = '2'):

AREA A FILE <b>PATH2</b> IS A REQUIRED FIELD.

==> The word PATH and 2 are joined together. Why is that so?

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    Posted on Oct 19, 2007 at 03:05 PM

    hi Kian,

    you should do:

    CONCATENATE ... INTO ... <b>SEPARATED BY SPACE</b>.

    ec

    Message was edited by:

    Eric Cartman

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 19, 2007 at 03:05 PM

    Kian,

    try this...

     CONCATENATE 'AREA A FILE PATH ' TXT_FILENUMBER ' IS A REQUIRED FIELD.' INTO MAND_ERR_MSG SEPARATED BY SPACE.

    Chandra.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 19, 2007 at 03:05 PM

    Hi,

    Put a SPACE key word in between PATH & TXT_FILENUMBER.

    Satish

    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.