Check on multiple header line data.

Hi All,
I have one requirement where i need to check the multiple accounting document header line.
Kindly suggest how to check the above requirement.
Thanks in Advance!
Regards,
Chirag

Hi All,
Sorry for the short description.
Currently i am validating only the one header line data of expense spread sheet file with vendor. but the now requirement has changed and there can be a multiple header line item also.
So i need to check for each header line item whether vendor already exist or not.
I am able to check it for 1 header line item, Kindly suggest how to check it for multiple header line item.
Thankyou.
Chirag

Similar Messages

  • Multiple Header line in Receiver File adapter

    Hi,
    I have an issue in Receiver File adapter with multiple header lines. I am able to get only 1 header lines in the receiver file but not multiple header lines with 'nl' since it is static in file mode
    [CommunityTag:Header]
    empNo,EmpName,Age
    [CommunityTag]
    I tried with the below in content conversion one as below with no luck
    Root.addHeaderLine=1
    Root.headerLine=[CommunityTag:Header] 'nl' empNo,EmpName,Age 'nl' [CommunityTag]
    Root.fiedSeparator=,
    Root.endSeparator='nl'
    I am getting the Header line as same row as static text.
    Can you advise this.

    Hi Gabriel, I suggest to produce the header lines from additional nodes in the message payload. That means you need to modify the data type of the target message in order to generate an extra structure in the payload. Use constants in message mapping to generate the header column names, e.g.
    <Header>
      <H1>CommunityTag:Header</H1>
      <H2>empNo,EmpName,Age</H2>
      <H3>CommunityTag</H3>
    </Header>
    In content conversion you have to convert the Header row with
    Header.endSeparator='nl'
    You won't need parameter addHeaderLine anymore then.
    Regards, Martin

  • Flat file having multiple header lines , how to separate the same and pushit into my intrnal table

    Hi Guys,
                    I got an issue , My flat file having multiple header lines
    TPS27RPR  MOME                                      THRIFT (SAVING) PLAN SYSTEM                                           Page    2
    09:54 05 JAN 2014                          List of Contributors w/Company Contributions                           Phase DAY Unit TRE
    Company No: xxxxxxxx - xxxxxxxxxxxxx.
                                                                            Employee/       Employee/
    Employee Full Name/                                                       Company         Company                        Allocation
    Number  ID Number                           PS  PN  End Date        Contribution          Profit        Total Balance   Percentage
    some lines of data and again
    TPS27RPR  MOME                                      THRIFT (SAVING) PLAN SYSTEM                                           Page    2
    09:54 05 JAN 2014                          List of Contributors w/Company Contributions                           Phase DAY Unit TRE
    Company No: xxxxxxxx - xxxxxxxxxxxxx.
                                                                            Employee/       Employee/
    Employee Full Name/                                                       Company         Company                        Allocation
    Number  ID Number                           PS  PN  End Date        Contribution          Profit        Total Balance   Percentage
    in this case how could I separate the header lines from the flat file and update the details to my internal table.
    kindly help me on this issue.
    Thanks and regards,
    M.S.Amirtharajvijay.

    Hi Amirthraj,
    If the flat file is static (if the content within it is same for all) then use the offset concept. First get the contents of the flat file into an internal table and later find the field that has to be in final internal table within the line, calculate the offset for the line and get the value into an workarea. Finally modify/append the work area into an internal table. Also wait for other experts answers for any other hassle free way to achieve the requirement.
    With Regards,
    Giriesh M

  • Multiple Header Line In HIERSEQ ALV

    Hi Experts,
    Please guide me how to get miltile Header lines in the HIERSEQ Alv , My requirment it develop a genledger for customers in which the Address of customer should be in 3 or four lines then followed by its balances. Please suggest me ...
    Regards,
    Prakash

    Hi,
    You need to pass the Row number to the filed catlog in order to display multiple header lines.
    For example,
       wl_fieldcat-row_pos = 1.  " This field will be displayed in first row
      wl_fieldcat-col_pos     = 1.
      wl_fieldcat-fieldname   = 'VBELN'.
      wl_fieldcat-tabname     = 'T_VBAK'.
      wl_fieldcat-outputlen   = 20.
      Append wl_fieldcat to t_fieldcat.
      wl_fieldcat-row_pos = 2.    " This field will be displayed in Second row
      wl_fieldcat-col_pos     = 1.
      wl_fieldcat-fieldname   = 'VBELN'.
      wl_fieldcat-tabname     = 'T_VBAK'.
      wl_fieldcat-outputlen   = 20.
      Append wl_fieldcat to t_fieldcat.
    Regards,
    Rajneesh

  • Multiple Header Lines in Flat-File read by FileSenderAdapter

    Hello XI and File Sender Adapter Species
    We have the following file with fixed file lengths:
    #H1 F1
    #H2 F1
    #H3 F1
    #H4 F1
    #H5 F1
    #H6 F1
    #D1 Field1 - Fieldn
    #D2 Field1 - Fieldm
    #D2 Field1 - Fieldm
    #D1 Field1 - Fieldn
    #D2 Field1 - Fieldm
    #D2 Field1 - Fieldm
    #F F1
    Concrete example as follows:
    #H1 150
    #H2 ECH150_20070709_026745152.dat
    #H3 20070709_1600
    #H4 9.0
    #H5 8712423010208
    #H6 8712423009202
    #MDDTD3 146307732 146202845 871687940006178374E70871687910000219120200707090032B 040235031             Noordkant               28         SINT ANTHONIS           5845EW                                   8716879000004871242300920287124230091962007070909550113533533                 8716948000010501000L
    #MDDTD4 59664          E10
    #MDDTD4 30180          E11
    #MDDTD3 146309776 146202839 871694840030212726E70871694830000000309200707090031B 0411   8              Flierakkers             21         VROOMSHOOP              7681XV                                   8716948000003871242300920287124230091962007070909590113533515                 8716948000010503000L
    #MDDTD4 3562           E10
    #MDDTD4 2422           E11
    #F6
    This File Should be read via the File Sender Adapter and afterwards mapped into the following idoc structure:
    IDOC-Type
    ZUECH_010
      Header Segment: H1, H2, H3, H4 , H5 ,H6
      Detail1Segment: Field1, Field2 …. Fieldn
      Detail2Segment: Field1, Field2 …. Fieldm
      Detail2Segment: Field1, Field2 …. Fieldm
      Detail1Segment: Field1, Field2 …. Fieldn
      Detail2Segment: Field1, Field2 …. Fieldm
      Detail2Segment: Field1, Field2 …. Fieldm
      FooterSegment: Field1
    Now my Questions:
    1.     As far as I know it is not possible to configure in the filesender adapter 2 different Record sets? We need two record sets, one for the header lines whose occurrences are once per File and one for the detail lines? Does anybody know if this is possible?
    2.     Any other ideas for a simple solution?
    Thanks for a soon answer.
    Regards Marlies

    Thanks all very much for your answers:
    The hint from Praveen was very helpful.
    If possible we need a solution with the graphical mapping tool and as far as possible without UDF, because at the moment there is no java developer.
    The file adapter now produces the following xml structure:
    <ZUECH_0150>
      <recordset>
        <H1>     
         <KH1>#H1</KH1>
         <H1>150</H1>
        </H1>
        <H2>
         <KH2>#H2</KH2>
                       <H2>ECH150_20070709_026745152.dat</H2>
              </H2>
              <H3>
                   <KH3>#H3</KH3>
                   <H3>20070709_1600</H3>
              </H3>
              <H4>
                   <KH4>#H4</KH4>
                   <H4>9.0</H4>
              </H4>
              <H5>
                   <KH5>#H5</KH5>
                   <H5>8712423010208</H5>
              </H5>
              <H6>
                   <KH6>#H6</KH6>
                   <H6>8712423009202</H6>
              </H6>
              <MDDTD3>
                   <KMDDTD3>#MDDTD3</KMDDTD3>
                   <MDDTD3>146307732 146202845 </MDDTD3>
              </MDDTD3>
              <MDDTD4>
                   <KMDDTD4>#MDDTD4</KMDDTD4>
                   <MDDTD4>59664          E10</MDDTD4>
              </MDDTD4>
              <MDDTD4>
                   <KMDDTD4>#MDDTD4</KMDDTD4>
                   <MDDTD4>30180          E11</MDDTD4>
              </MDDTD4>
         </recordset>
    </ ZUECH_0150>
    I would prefer the following structure, because it fits exactly to the structure of the idoc.
    That means the mapping is very simple:
    <ZUECH_0150>
          <HEADER>
                  <H1>150</H1>
                  <H2> ECH150_20070709_026745152.dat</H1>
          </HEADER>
          <MDDTD3>
                 <KMDDTD3></KMDDTD3>
                 <MDDTD3>146307732 146202845</MDDTD3>
                    <MDDTD4>
                   <KMDDTD4>#MDDTD4</KMDDTD4>
                   <MDDTD4>59664          E10</MDDTD4>
              </MDDTD4>
              <MDDTD4>
                   <KMDDTD4>#MDDTD4</KMDDTD4>
                   <MDDTD4>30180          E11</MDDTD4>
              </MDDTD4>
          </MDDTD3>
    </ZUECH_0150>
    Now my new questions:
    1.     Is it possible to configure the file adapter to produce a xml structure which afterwards can be mapped with a simple graphical mapping into the idoc structure?
    (I can live with the suggestion from Praveen, that the header information is in each recordset but only has content in the first one.)
    2.     What about the MDDTD4? It is a substructure from MDDTD3. Is it possible to configure this in the file adapter?
    Thanks a lot for your help and a soon answer.
    Regards Marlies
    Message was edited by:
            Marlies  Nowotka
    Message was edited by:
            Marlies  Nowotka

  • How to get multiple header lines dynamically and also data hierarchically using ALV

    Hi experts,
    My requirement is shown below.. I neet to compare prices of service RFQs. So i design as below..
    I want to get RFQ number ,Vendor code and vendor name in ALV header and also other headings which static. I think dynamic table is the best way to load RFQ numbers to header.. But problem is i'm unable to load two lines dynamically using ALV.
    CALL METHOD cl_alv_table_create=>create_dynamic_table
         EXPORTING
           i_style_table             = 'X'
           it_fieldcatalog           = gt_dyn_fcat
         IMPORTING
           ep_table                  = gt_dyn_table
         EXCEPTIONS
           generate_subpool_dir_full = 1
           OTHERS                    = 2.
    I use this function and pass RFQ no and vendor code in two rows but it output gt_dyn_table in same row.. How to print them as given image???
    Then in data I want to get service items and according to the external service number divide them to groups and get sub totals and also finally total of all sub categories to compare each RFQs price to  compare.. There i think ALV hierarch can use. but not sure I can use with dynamic table(in header use it).
    What is thee best way to get the output in my image..??
    Thanks..
    Pavi

    Hi experts,
    My requirement is shown below.. I neet to compare prices of service RFQs. So i design as below..
    I want to get RFQ number ,Vendor code and vendor name in ALV header and also other headings which static. I think dynamic table is the best way to load RFQ numbers to header.. But problem is i'm unable to load two lines dynamically using ALV.
    CALL METHOD cl_alv_table_create=>create_dynamic_table
         EXPORTING
           i_style_table             = 'X'
           it_fieldcatalog           = gt_dyn_fcat
         IMPORTING
           ep_table                  = gt_dyn_table
         EXCEPTIONS
           generate_subpool_dir_full = 1
           OTHERS                    = 2.
    I use this function and pass RFQ no and vendor code in two rows but it output gt_dyn_table in same row.. How to print them as given image???
    Then in data I want to get service items and according to the external service number divide them to groups and get sub totals and also finally total of all sub categories to compare each RFQs price to  compare.. There i think ALV hierarch can use. but not sure I can use with dynamic table(in header use it).
    What is thee best way to get the output in my image..??
    Thanks..
    Pavi

  • Multiple Header Lines

    Hi Gurus
    When I enter a header condition in the sales order and activate it,system automatically inserts a line for the same condition type but with condition value displayed.. I don't want this to happen.Could you please tell me where I can change the settings.
    Thanks
    Kumar

    Hi kumar,
    First as far as i see your header condtion base concept is not clear.
    system will automatically divide the value of the header condtion in the line items .
    Read the following to gain more insight in to the functionality
    Header conditions are those which appear in the header level of any sales order. these conditions are to be entered manually and get distributed automatically and the basis for distribution are taken from the NET VALUE of items mentioned at item level. 
    When we go to the conditions section in a sales order, where the details of pricing is mentioned, here we add these conditions. 
    Whenever any Header Condition is used, it overrides the PR00 condition type.
    Examples of header condition.
    - HA00 - % Based Header Condition. 
    - RB00 - Absolute or numeric value which applies to all items.
    - HB00 - Numeric value or Absolute value.   
    Usage of this feature is to apply price / discount for a specific group of materials. 
    1. You maintained a discount based condition record fbased on material group ( = 01 for example). You maintained scales also.
         Qty      Discount          
        1 - 10   Rs. 100.00
      11 - 50   Rs. 105.00
    51 - 150   Rs. 110.00 etc.
    2. You are creating a sales order for a customer with five different items with different quantities as below
    ITEM 1 - 25 No's
    ITEM 2 - 3 No's
    ITEM 3 - 12 No's
    ITEM 4 - 27 No's
    ITEM 5 - 62 No's
    All the material is having the material group = 01.
    3. While calculating the discount, because of this group condition, system add the quantities of items which have material group = 01. In the above example total quantity is = 109. System apply a discount of Rs. 110.00 to each item irrespective of the individual quantities.
    4. If you have not activated the group condition feature, system determines the discount value based on individual item quantity which is as below.
                                          Discount
    ITEM 1 - 25 No's         Rs. 105.00
    ITEM 2 -   3 No's         Rs. 100.00
    ITEM 3 - 12 No's         Rs. 105.00
    ITEM 4 - 27 No's         Rs. 105.00
    ITEM 5 - 62 No's         Rs. 115.00
    5. Is it clear now. Just try a sales order and see the out come
    Procedure to Test:
    1. Create 3 materials. Maintain Material Group of each item is same. 
    2. Activate the condition type as a group condition. 
    3. Create a condition record for this condition type with scales. 
    4. Process a sales order for a customer with these three material with different quantities. 
    5. Check the outcome.     
    Revert if helpful
    Mohit Singh

  • Multiple Header Lines for the ALV  Layout

    Hi Experts,
    I am working on a ALV report in MM , the output should be like mentioned below, I have tried this by using  ALV List , I got it then ,  but I want the output by using  ALV Grid ( Function Modules / Classes ).
    Material
    Branch
    Material No
    Created on
    Material Type
    Plant
    Valuation Category
        1343                 29/06/09            HALB                     HKM1                   01                        
        1342                 28/06/09            HALB                     HKM1                   01  
        1341                 27/06/09            HALB                     HKM1                   01   
        1340                 26/06/09            HALB                     HKM1                   01
        1339                 25/06/09            HALB                     HKM1                   01
        1338                 24/06/09            HALB                     HKM1                   01
    Thanks
    V. Venkatesh

    check the standard program  BALVHD01_GROUP
    http://www.geocities.com/mpioud/Z_ALV_HIERSEQ_LIST.html

  • Moving data into internal table without header line

    Hello experts.
    i have two internal tables . itab1 without headerline and itab2 with headerline. itab1 has 10 fields and itab2 has 2 fields.
    BEGIN OF itab,
            lifnr LIKE lfa1-lifnr,
            ktokk LIKE lfa1-ktokk,
            name1 LIKE lfa1-name1,
            sortl LIKE lfa1-sortl,
            pstlz LIKE lfa1-pstlz,
            ort01 LIKE lfa1-ort01,
            land1 LIKE lfa1-land1,
           j_1ipanno LIKE j_1imovend,
    end of itab.
    DATA: itab1 TYPE STANDARD TABLE OF itab.
    data: begin of itab2 occurs 0,                             
          lifnr like j_1imovend-lifnr,
          j_1ipanno like j_1imovend-j_1ipanno,
      end of itab2.
    now i want to move the data from itab2-j_1ipanno into itab1-j_1ipanno. so pls tell me how to do that. lifnr in both the tables are the same.
    thanks for all the replies.

    Hi Shiva,
    In with out header line,
    You declare header line & body separately like
    data: IT_MARA type standard table of MARA,
    WA_MARA like line of IT_MARA.
    Advantages:
    1. Clear differentiation of header line over body
    2. It is must in the ABAP Objects to have separate header line & body
    3. Use ful in Nested Internal tables
    Disadvantages:
    1. Long syntax
    for example: Loop at IT_MARA into WA_MARA.
    In with header line
    Data ITAB like MARA occurs 0 with header line.
    Advantages:
    1. Simple to use & declare over without header line.
    Also,
    With Header line:
    codedata : itab like <dbtable> occurs 0 with header line.
    Data: begin of itab occurs 0,
    f1 type f1,
    f2 type f2,
    end of itab.[/code]
    Without Header line.
    codeTypes: begin of ty_tab,
    f1 type f1,
    f2 type f2,
    end of ty_tab.
    Data: itab type table of ty_tab, " Internal Table
    wa type ty_tab. " Work Area[/code]
    at any point of time use internal table without header line,it will be good performance as well OO ABAP will allow only internal table without header line.
    Just use one simple example :
    create one simple program with header line,use get run time field.
    create one simple program without header line,use get run time field.
    see the results ,here time will be micro seconds,so take 1000 records to internal table and do calculate the time.
    While adding or retrieving records to / from internal table we have to keep the record temporarily.
    The area where this record is kept is called as work area for the internal table. The area must have the same structure as that of internal table. An internal table consists of a body and an optional header line.
    Header line is a implicit work area for the internal table. It depends on how the internal table is declared that the itab will have the header line or not.
    e.g.
    data: begin of itab occurs 10,
    ab type c,
    cd type i,
    end of itab. " this table will have the header line.
    data: wa_itab like itab. " explicit work area for itab
    data: itab1 like itab occurs 10. " table is without header line.
    The header line is a field string with the same structure as a row of the body, but it can only hold a single row.
    It is a buffer used to hold each record before it is added or each record as it is retrieved from the internal table. It is the default work area for the internal table.
    kindly reward if found helpful.
    cheers,
    Hema.

  • How to get schedule line date copied to "First date" in sales order

    Dear forum
    I am creating a sales order as normal and put in a Requested Delivery Date (KETDAT) for the order.
    This requested delivery date is then copied to the "First date" (ETDAT).
    Now, the ATP is checked for each line item in the order and a Schedule line date / material availability date is calculated for each line item.
    My question is: Is there any way to have the "First date" field of the line item in the sales order populated by the first material availability date (calculated by ATP), instead of copying the Requested  Delivery Date? Any user exit? Any config?
    It would mean that every time I rerun ATP check in the sales order line item, the "First date" field would change if the material availability date change. If there is multiple material availability (multiple schedule lines) dates per line item, then the earliest date would be copied to the "First date" field.
    Is there such functionality? Or possibility to config/program?
    /Ola

    Kannan
    OK. Unfortunately reservations cannot be created at the serial number level. So the unsupported way of doing this is updating the mtl_serial_numbers tables. I hope you would know (by some means) which serial numbers you want to allocate to a specific sales orders. If you know, update group_mark_id column in mtl_serial_numbers table with your order_line_Id, This will avoid any one from picking the serial numbers (they will not come up in the LOV or will not be auto allocated).
    But you have to make sure to take it off when you actually want to pick this order line and allocate this serial number. So just before you pick release/ confirm this order line you need to update column back to null so that you can allocate that serial number.
    Thanks
    Nagamohan

  • Header, Line Item and Cache Techniques Using Hashed Tables

    Hi,
    How can I work with header, line item, and a cache techniques using hashed tables?
    Thanks,
    Shah.

    Hi,
    Here is an example to clarify the ideas:
    In general, every time you have a header-> lines structure you have a unique key for the lines that has at least header key plus one or more fields. I'll make use of this fact.
    I'll try to put an example of how to work with header -> line items and a cache technique using hashed tables.
    Just suppose that you need a list of all the material movements '101'-'901' for a certain range of dates in mkpf-budat. We'll extract these fields:
    mkpf-budat
    mkpf-mblnr,
    mseg-lifnr,
    lfa1-name1,
    mkpf-xblnr,
    mseg-zeile
    mseg-charg,
    mseg-matnr,
    makt-maktx,
    mseg-erfmg,
    mseg-erfme.
    I'll use two cache: one for maintaining lfa1 related data and the other to maintain makt related data. Also I'll only describe the data gathering part. The showing of the data is left to your own imagination.
    The main ideas are:
    1. As this is an example I won't use inner join. If properly desingned may be faster .
    2. I'll use four hashed tables: ht_mkpf, ht_mseg, ht_lfa1 and ht_makt to get data into memory. Then I'll collect all the data I want to list into a fifth table ht_lst.
    3. ht_mkpf should have (at least) mkpf's primary key fields : mjahr, mblnr.
    4. ht_mseg should have (at least) mseg primary key fields: mjahr mblnr and zeile.
    5. ht_lfa1 should have an unique key by lifnr.
    6. ht_makt should have an unique key by matnr.
    7. I prefer using with header line because makes the code easier to follow and understand. The waste of time isn't quite significant (in my experience at least).
    Note: When I've needed to work from header to item lines then I added a counter in ht_header that maintains the count of item lines, and I added an id in the ht_lines so I can read straight by key a given item line. But this is very tricky to implement and to follow. (Nevertheless I've programmed it and it works well.)
    The data will be read in this sequence:
    select data from mkpf into table ht_mkpf
    select data from mseg int table ht_mseg having in count all the data in ht_mkpf
    loop at ht_mseg (lines)
    filter unwanted records
    read cache for lfa1 and makt
    fill in ht_lst and collect data
    endloop.
    tables
    tables: mkpf, mseg, lfa1, makt.
    internal tables:
    data: begin of wa_mkpf, "header
    mblnr like mkpf-mblnr,
    mjahr like mkpf-mjahr,
    budat like mkpf-budat,
    xblnr like mkpf-xblnr,
    end of wa_mkpf.
    data ht_mkpf like hashed table of wa_mkpf
    with unique key mblnr mjahr
    with header line.
    data: begin of wa_mseg, " line items
    mblnr like mseg-mblnr,
    mjahr like mseg-mjahr,
    zeile like mseg-zeile,
    bwart like mseg-bwart,
    charg like mseg-charg,
    matnr like mseg-matnr,
    lifnr like mseg-lifnr,
    erfmg like mseg-erfmg,
    erfme like mseg-erfme,
    end of wa_mseg,
    data ht_mseg like hashed table of wa_mseg
    with unique key mblnr mjahr zeile
    with header line.
    data: begin of wa_lfa1,
    lifnr like lfa1-lifnr,
    name1 like lfa1-name1,
    end of wa_lfa1,
    data ht_lfa1 like hashed table of wa_lfa1
    with unique key lifnr
    with header line.
    data: begin of wa_makt,
    matnr like makt-matnr,
    maktx like makt-maktx,
    end of wa_makt.
    data: ht_makt like hashed table of wa_makt
    with unique key matnr
    with header line.
    result table
    data: begin of wa_lst, "
    budat like mkpf-budat,
    mblnr like mseg-mblnr,
    lifnr like mseg-lifnr,
    name1 like lfa1-name1,
    xblnr like mkpf-xblnr,
    zeile like mseg-zeile,
    charg like mseg-charg,
    matnr like mseg-matnr,
    maktx like makt-maktx,
    erfmg like mseg-erfmg,
    erfme like mseg-erfme,
    mjahr like mseg-mjahr,
    end of wa_mseg,
    data: ht_lst like hashed table of wa_lst
    with unique key mblnr mjahr zeile
    with header line.
    data: g_lines type i.
    select-options: so_budat for mkpf-budat default sy-datum.
    select-options: so_matnr for mseg-matnr.
    form get_data.
    select mblnr mjahr budat xblnr
    into table ht_mkfp
    from mkpf
    where budat in so_budat.
    describe table ht_mkpf lines g_lines.
    if lines > 0.
    select mblnr mjahr zeile bwart charg
    matnr lifnr erfmg erfme
    into table ht_mseg
    from mseg
    for all entries in ht_mkpf
    where mblnr = ht_mkpf-mblnr
    and mjahr = ht_mjahr.
    endif.
    loop at ht_mseg.
    filter unwanted data
    check ht_mseg-bwart = '101' or ht_mseg-bwart = '901'.
    check ht_mseg-matnr in so_matnr.
    read header line.
    read table ht_mkpf with table key mblnr = ht_mseg-mblnr
    mjahr = ht_mseg-mjahr.
    clear ht_lst.
    note : this may be faster if you specify field by field.
    move-corresponding ht_mkpf to ht_lst.
    move-corresponding ht_mseg to ht_lst.
    perform read_lfa1 using ht_mseg-lifnr changing ht_lst-name1.
    perform read_makt using ht_mseg-matnr changing ht_lst-maktx.
    insert table ht_lst.
    endloop.
    implementation of cache for lfa1.
    form read_lfa1 using p_lifnr changing p_name1.
    read table ht_lfa1 with table key lifnr = p_lifnr
    transporting name1.
    if sy-subrc <> 0.
    clear ht_lfa1.
    ht_lfa1-lifnr = p_lifnr.
    select single name1
    into ht_lfa1-name1
    from lfa1
    where lifnr = p_lifnr.
    if sy-subrc <> 0. ht_lfa1-name1 = 'n/a in lfa1'. endif.
    insert table ht_lfa1.
    endif.
    p_name1 = ht_lfa1-name1.
    endform.
    implementation of cache for makt
    form read_makt using p_matnr changing p_maktx.
    read table ht_makt with table key matnr = p_matnr
    transporting maktx.
    if sy-subrc <> 0.
    ht_makt-matnr = p_matnr.
    select single maktx into ht_matk-maktx
    from makt
    where spras = sy-langu
    and matnr = p_matnr.
    if sy-subrc <> 0. ht_makt-maktx = 'n/a in makt'. endif.
    insert table ht_makt.
    endif.
    p_maktx = ht_makt-maktx.
    endform.
    Reward points if found helpfull...
    Cheers,
    Siva.

  • With header line & with out header line ?

    what is difference between with header line & without header line ?

    When you create an internal table object you can also declare a header line with the same name. You can use the header line as a work area when you process the internal table. The ABAP statements that you use with internal tables have short forms that you can use if your internal table has a header line. These statements automatically assume the header line as an implicit work area. The following table shows the statements that you must use for internal tables without a header line, and the equivalent statements that you can use for internal tables with a header line:
    Operations without header line
    Operations with header line
    Operations for all Table Types
    INSERT <wa> INTO TABLE <itab>.
    INSERT TABLE ITAB.
    COLLECT <wa> INTO <itab>.
    COLLECT <itab>.
    READ TABLE <itab> ... INTO <wa>.
    READ TABLE <itab> ...
    MODIFY TABLE <itab> FROM <wa> ...
    MODIFY TABLE <itab> ...
    MODIFY <itab> FROM <wa> ...WHERE ...
    MODIFY <itab> ... WHERE ...
    DELETE TABLE <itab> FROM <wa>.
    DELETE TABLE <itab>.
    LOOP AT ITAB INTO <wa> ...
    LOOP AT ITAB ...
    Operations for Index Tables
    APPEND <wa> TO <itab>.
    APPEND <itab>.
    INSERT <wa> INTO <itab> ...
    INSERT <itab> ...
    MODIFY <itab> FROM <wa> ...
    MODIFY <itab> ...
    Using the header line as a work area means that you can use shorter statements; however, they are not necessarily easier to understand, since you cannot immediately recognize the origin and target of the assignment. Furthermore, the fact that the table and its header line have the same name can cause confusion in operations with entire internal tables. To avoid confusion, you should use internal tables with differently-named work areas.
    The following example shows two programs with the same function. One uses a header line, the other does not.
    With header line:
    TYPES: BEGIN OF LINE,
    COL1 TYPE I,
    COL2 TYPE I,
    END OF LINE.
    DATA ITAB TYPE HASHED TABLE OF LINE WITH UNIQUE KEY COL1
    WITH HEADER LINE.
    DO 4 TIMES.
    ITAB-COL1 = SY-INDEX.
    ITAB-COL2 = SY-INDEX ** 2.
    INSERT TABLE ITAB.
    ENDDO.
    ITAB-COL1 = 2.
    READ TABLE ITAB FROM ITAB.
    ITAB-COL2 = 100.
    MODIFY TABLE ITAB.
    ITAB-COL1 = 4.
    DELETE TABLE ITAB.
    LOOP AT ITAB.
    WRITE: / ITAB-COL1, ITAB-COL2.
    ENDLOOP.
    Without header line:
    TYPES: BEGIN OF LINE,
    COL1 TYPE I,
    COL2 TYPE I,
    END OF LINE.
    DATA: ITAB TYPE HASHED TABLE OF LINE WITH UNIQUE KEY COL1,
    WA LIKE LINE OF ITAB.
    DO 4 TIMES.
    WA-COL1 = SY-INDEX.
    WA-COL2 = SY-INDEX ** 2.
    INSERT WA INTO TABLE ITAB.
    ENDDO.
    WA-COL1 = 2.
    READ TABLE ITAB FROM WA INTO WA.
    WA-COL2 = 100.
    MODIFY TABLE ITAB FROM WA.
    WA-COL1 = 4.
    DELETE TABLE ITAB FROM WA.
    LOOP AT ITAB INTO WA.
    WRITE: / WA-COL1, WA-COL2.
    ENDLOOP.
    The list, in both cases, appears as follows:
    1 1
    2 100
    3 9
    The statements in the program that does not use a header line are easier to understand. As a further measure, you could have a further work area just to specify the key of the internal table, but to which no other values from the table are assigned.
    Internal table with header line
    you can use anywhere except obkect oriented concept.
    Internal table without header line :
    You should use in Object oriented concept..
    Always try to use without header line,performance point of view it is best..
    Example :
    Without header line.
    Structure
    types : begin of ty_itab ,
    matnr type mara-matnr,
    end of ty_itab.
    Internal table
    data i_itab type standard table of ty_itab .
    Work area
    data wa_itab like line of i_itab
    With header line
    data : begin of i_itab occurs 0,
    matnr like mara-matnr,
    end of i_itab
    itab with header lines are obsolete, anyway it will work but not recommended. instead use work area or more effiecient is field symbols. so donot use itab with header line.
    i will explain use of itab w/o header line.
    Data: itab1 type standard table of mara with header line occurs 0,
            itab2 type standard table of mara,
            wa_itab2 type mara.
    loop at itab1.
    "This will work fine.
    endloop.
    loop at itab2.
    "This will give erro that itabd does not hav workarea
    endloop.
    "so write
    loop at itab2 into wa_itab2.
    "This will work
    endloop.
    <b>The difference between
    whih header line and with out heater line of internal table.
    ex:-
    a) Data : itab like mara occurs 0 with header line.
    b) Data: itab like mara occurs 0.
    -While adding or retrieving records to / from internal table we have to keep the record temporarily.
    -The area where this record is kept is called as work area for the internal table.
    -The area must have the same structure as that of internal table. An internal table consists of a body and an optional header line.
    -Header line is a implicit work area for the internal table. It depends on how the internal table is declared that the itab will have the header line or not.
    a) Data : itab like mara occurs 0 with header line.
    table is with header line
    b) Data: itab like mara occurs 0.
    table is without header line</b>
    regards,
    srinivas
    <b>*reward for useful answers*</b>

  • Header, line and adress details

    hi experts,
    actually i am working on outbound iunterface.
    in the target structure it is given as ,
    1.header,
    2, line items,
    3, adress.
    using my select statements i have retrived the data and in the target structure the data should be displayed as
    1.header,
    2, line items,
    3, adress.
    plz suggest me how to do.
    regards,
    siri.

    Hi rajesh,
    Header is a workarea of the table which acts as an interface for the table. Header can have only one record at a time.
    WORKAREA is a structure that can hold only one record at a time. It is a collection of fields. We use workarea as we cannot directly read from a table. In order to interact with a table we need workarea. When a Select Statement is executed on a table then the first record is read and put into the header of the table and from there put into the header or the workarea(of the same structure as that of the table)of the internal table and then transferred top the body of the internal table or directly displayed from the workarea.
    Each row in a table is a record and each column is a field.
    example,
    internal table.
    data: begin of itab occurs 0,
    matnr like mara-matnr,
    maktx like makt-maktx,
    end of itab.
    workarea.
    data: begin of itab,
    matnr like mara-matnr,
    maktx like makt-maktx,
    end of itab.
    also,
    workarea:
    types: begin of type_mat,
    matnr like mara-matnr,
    maktx like makt-maktx,
    end of type_mat.
    internal table
    data: t_mat type standard table of type_mat.
    data: begin of itab occurs 10,
    ab type c,
    cd type i,
    end of itab. " this table will have the header line.
    data: wa_itab like itab. " explicit work area for itab
    data: itab1 like itab occurs 10. " table is without header line.
    The header line is a field string with the same structure as a row of the body, but it can only hold a single row.
    It is a buffer used to hold each record before it is added or each record as it is retrieved from the internal table. It is the default work area for the internal table.

  • Header line not displaed in MT103 Format

    Hi all,
    We are working on MT103 format, we are not getting the header line data
    In image 1 we are getting "HKBCCATT 103" but in image 2 we are not getting that line.
    Kindly help us what should be done so we can get "HKBCCATT 103"
    Regards,
    shegar.

    Hi,
    It would have helped if you had indicated in any way what functionality are you using to produce the file... If I look at the settings for MT103 in transaction OBPM1, and the event module for Event 20 - Start/File header, the standard event implementation FM FI_PAYMEDIUM_MT103_20 takes in into gs_swift_103 structure as part of format parameters the field PAYMHEAD, which controls writing of header record. But since you didn't bother to supply any information whatsoever, one can only guess if this is applicable to your case...
    cheers
    Jānis

  • Diff between header line and work area.

    Diff between header line and work area.

    Hi,
    These are table with header line.
    DATA: T_TABLE type table of <table_name> with header line.
    data: begin of t_table occurs 0,
                  field1 type ...
                  field2 type ...
                  field3 type ...
          end of t_table.
    <b>The result is:</b>
    <u><b>TABLE</b></u>    
    FIELD NAME  |FIELD1|FIELD2|FIELD3|  
    HEADER LINE |EE1   |EE2   |EE3   | <---- Line 5 content
               1|AA1   |AA2   |AA3   |  
               2|BB1   |BB2   |BB3   |  
               3|CC1   |CC2   |CC3   |
               4|DD1   |DD2   |DD3   |
               5|EE1   |EE2   |EE3   |
    These are table without header line.
    DATA: T_TABLE type table of <table_name>.
    DATA: T_TABLEX LIKE TABLE OF t_table.
    <b>The result is:</b>
    <u><b>TABLE</b></u>    
    FIELD NAME  |FIELD1|FIELD2|FIELD3|  
                     0|---   |---   |---   | <---- No header Line
                     1|AA1   |AA2   |AA3   |  
                     2|BB1   |BB2   |BB3   |  
                     3|CC1   |CC2   |CC3   |
                     4|DD1   |DD2   |DD3   |
                     5|EE1   |EE2   |EE3   |
    These are work areas:
    Tables <table>.
    DATA: wa type <table>.
    DATA: wa like t_table.
    DATA: wa type line of <table>.
    <b>The result is:</b>
    <u><b>WORK AREA</b></u>  
    |EE1   |EE2   |EE3   | <---- Content
    Regards.
    Marcelo Ramos

Maybe you are looking for

  • Hyperlink in Subscreen - Respond to double click is not responding

    Hi Team, I have a requirement - i need to have a Hyperlink in he sub screen , i tried keeping an input box , checked responding to double click , but nothing is triggering when double clicking(I tried debugging but not triggering). Please let me know

  • Stretched QT Export

    I've imported into FCExpress 2 from a Sony Digital 8 Handycam through Firewire. All looks good in FCExp (regular non-HD, TV-like aspect ratio). But when I export to QT Movie and play back in QT Player, the image is stretched horizontally (everyone be

  • Connection to wired computers through Airport

    I have a wired network in my house with a Linksys firewall/router. I just added an Airport Extreme, in order to be able to also have wireless access for a couple MacBook Pros. The setup of the Airport Extreme and connection to the MBPs appeared to go

  • Possible to RAID 0 and run Boot Camp partition?

    I have a mid-2010 MacBook Pro (13"). I have a stock 250 GB hard drive and I just got a SanDisk 256 GB SSD. I'm running Windows (through Boot Camp) on a small partition of my stock 250 GB hard drive. I want to install the SSD in my optical drive and R

  • Printer issue with epson WF 2540

    All of a sudden, I'm unable to see print when printing an Adobe PDF or a TextEdit file. I AM able to print from a screen grab. Yosemite 10.10.3 Apple says it's because Epson has not upgraded a driver for Yosemite. Epson says it's Apple's fault. Or mi