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

Merging of multiple rows in an internal table as a single record

Hi All,

I have an internal table which has the following columns:

text, date, time, user.

it stores notes in the internal table.

The problem is...when I save a note with multiple lines and spaces it saves each line of the note as a row in the internal table.

Thus i get more no. of rows in the internal table compare to the no. of rows!

I need to store each notes as single row in the internal table.

Please advise how to approach this?

Helpful answers will be rewarded.

Thanks & Regards,

Anshumita.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    Posted on Dec 01, 2007 at 11:08 AM

    Anshumita,

    I don't think that it is possible to store the whole notes as one record in the internal table.Why don't you try it by giving an internal table of the below structure.

    TYPES :BEGIN OF TY_ITAB2,

    DATA(400),

    END OF TY_ITAB2.

    DATA: ITAB3 TYPE TY_ITAB2 OCCURS 0 WITH HEADER LINE

    Loop at itab1.

    ITAB3-DATA = ITAB1-LABEL.

    APPEND ITAB3.

    ITAB3-DATA = ITAB1-MATNR.

    APPEND ITAB3.

    endloop.

    I am not sure whether this kind of internal table will help you or not.

    K.Kiran.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Dec 01, 2007 at 01:20 PM

    You can create a deep internal table. You can declare one Column as an internal table and store the NOTES in that Internal table for each row.

    http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb366d358411d1829f0000e829fbfe/content.htm

    you can check the example in the link

    regards,

    abhishek

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 30, 2007 at 11:58 PM

    HI Anshumita,

    Can you provide an example of the issue you face?

    Regards,

    RAVi

    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.