Outbound file interface - Header and item record transfer issue

Hi.
Pls help me complete this work by today:
I have to pass header and item record into file in application server.
I am retrieving Header record from table MCHB & RESB
and item record from MKOL & LFA1
I have to create separate file per plant ( plant is multiple selection field)
I have a check box (p_sob) for special stock selection in my selection screen .
If p_sob is initial
Header record should come from MCHB and RESB
and corresponding item entries from MKOL and LFA1
If some batch entries entries only exists in MCHB and not in MKOL then item fields will be blank
However if some entries exists only in MKOL and not in MCHB then header fields will be filled by correponding item fields.
Can anyone tell me the basic frame of the program.
Regards,
Simran

*&      Form  sub_populate_header
      Subroutine to populate header table
FORM sub_populate_header.
  DATA:   l_clabs   TYPE char13,     "Valuated stock
          l_bdmng   TYPE char13,     "Requirement quantity
          l_avqty   TYPE char13,     "Available quantity
          l_slabs   TYPE char13.     "Consignment stock
  DATA: i_mkol_tmp type standard table of ty_mkol initial size 0.
  LOOP AT i_mchb INTO wa_mchb.
    READ TABLE i_mkol INTO wa_mkol WITH KEY matnr = wa_mchb-matnr
                                            werks = wa_mchb-werks
                                            lgort = wa_mchb-lgort
                                            charg = wa_mchb-charg
                                            BINARY SEARCH.
    IF sy-subrc EQ 0.
*Mark those MKOL records for deletion
      wa_mkol-mark = c_mark.         "marked for deletion
    ELSE.
*Population of Plant,material number,batch,storage location and
*valuated stock
      wa_header-werks = wa_mchb-werks.              "Plant
      wa_header-matnr = wa_mchb-matnr.              "Material number
      wa_header-charg = wa_mchb-charg.              "Charg
      wa_header-lgort = wa_mchb-lgort.              "Storage location
      wa_header-clabs = wa_mchb-clabs.              "Valuated stock
      l_clabs = wa_header-clabs.
      SHIFT l_clabs LEFT DELETING LEADING space.
*Population of material description
      READ TABLE i_makt INTO wa_makt WITH KEY matnr = wa_header-matnr.
      IF sy-subrc EQ 0.
      wa_header-maktx = wa_makt-maktx.             "Material description
      ENDIF.
*Population of Requirement quantity
      READ TABLE i_sum INTO wa_sum WITH KEY charg = wa_header-charg
                                            BINARY SEARCH.
      IF sy-subrc EQ 0.
      wa_header-bdmng = wa_sum-bdmng.              "Requirement quantity
        l_bdmng = wa_header-bdmng.
        SHIFT l_bdmng LEFT DELETING LEADING space.
      ENDIF.
*Population of Available quantity
      l_avqty = l_clabs - l_bdmng.
      SHIFT l_avqty LEFT DELETING LEADING space.
      wa_header-avqty = l_avqty.                   "Available quantity
      APPEND wa_header TO i_header.
      CLEAR wa_header.
    ENDIF.
  ENDLOOP.
*Deleting batches from MKOL which exists in MCHB
  i_mkol_tmp[] = i_mkol[].
  DELETE i_mkol_tmp WHERE mark = c_mark.
*Sorting I_MKOL
  SORT i_mkol_tmp BY matnr werks charg lgort.
  LOOP AT i_mkol_tmp INTO wa_mkol_tmp.
*Population of Plant,Material number,charg & Storage location
    wa_header-werks = wa_mkol_tmp-werks.        "Plant
    wa_header-matnr = wa_mkol_tmp-matnr.        "Material number
    wa_header-charg = wa_mkol_tmp-charg.        "Batch number
    wa_header-lgort = wa_mkol_tmp-lgort.        "Storage location
    APPEND wa_header TO i_header.
    CLEAR wa_header.
  ENDLOOP.
ENDFORM.                    " sub_populate_header
*&      Form  sub_populate_item
      Subroutine to populate item table
FORM sub_populate_item .
  LOOP AT i_mkol INTO wa_mkol.
    wa_item-lifnr = wa_mkol-lifnr.      "Vendor number
    wa_item-slabs = wa_mkol-slabs.      "Consignment stock
    READ TABLE i_lfa1 INTO wa_lfa1 WITH KEY lifnr = wa_mkol-lifnr
                                            BINARY SEARCH.
    IF sy-subrc EQ 0.
      wa_item-name1 = wa_lfa1-name1.       "Vendor name
    ENDIF.
  ENDLOOP.
ENDFORM.                    " sub_populate_item
*&      Form  sub_batch_stock
      Subroutine to output batch record from table (MCHB & MKOL) into
      file in application server
FORM sub_batch_stock .
  DATA:   l_record TYPE string,      "String
          l_clabs   TYPE char13,     "Valuated stock
          l_bdmng   TYPE char13,     "Requirement quantity
          l_avqty   TYPE char13,     "Available quantity
          l_slabs   TYPE char13,     "Consignment stock
          l_tabix   TYPE sytabix.    "Index
  LOOP AT i_header INTO wa_header.
*Separate file per plant
    AT NEW werks.
*Creation of file
      PERFORM sub_create_file.
Open File on the application server for processing
      OPEN DATASET g_file_name FOR APPENDING IN TEXT MODE
      ENCODING DEFAULT.
      IF sy-subrc NE 0.
*Display error message
        MESSAGE e055 WITH g_file_name.         " Error in opening file
      ENDIF.
    ENDAT.
    AT NEW charg.
      CONCATENATE  c_header           " Header indentification
                   wa_header-werks    " Plant
                   wa_header-matnr    " Material number
                   wa_header-maktx      " Material description
                   wa_header-charg    " Batch number
                   wa_header-lgort    " Storage location
                   l_clabs            " Valuated stock-unrestricted use
                   l_bdmng            " Requirement quantity
                   l_avqty            " Avalable quantity.
              INTO l_record SEPARATED BY
                   cl_abap_char_utilities=>horizontal_tab.
Transfering header record to file
      TRANSFER l_record TO g_file_name.
      CLEAR: l_clabs,
             l_bdmng,
             l_avqty,
             l_record.
    ENDAT.
    LOOP AT i_mkol INTO wa_mkol WHERE matnr = wa_header-matnr
                                AND   werks = wa_header-werks
                                AND   charg = wa_header-charg
                                AND   lgort = wa_header-lgort.
*Population of Vendor number and consignment stock
      wa_item-lifnr = wa_mkol-lifnr.          "Vendor number
*Storing Consignment stock into local variable to change datatype
*from QUAN to CHAR
      l_slabs = wa_mkol-slabs.
      SHIFT l_slabs LEFT DELETING LEADING space.
      wa_item-slabs = l_slabs.                "Consignment stock
*Population of Vendor name
      READ TABLE i_lfa1 INTO wa_lfa1 WITH KEY lifnr = wa_mkol-lifnr
                                              BINARY SEARCH.
      IF sy-subrc EQ 0.
        wa_item-name1 = wa_lfa1-name1.        "Vendor name
      ENDIF.
    CONCATENATE   c_item           " Item identification
                wa_item-lifnr   " Vendor number
                wa_item-name1   " Vendor name
                l_slabs          " Consignment stock-unrestd. use
           INTO l_record SEPARATED BY
           cl_abap_char_utilities=>horizontal_tab.
*Transfering Item record into file
  TRANSFER l_record TO g_file_name.
  CLEAR: l_slabs,
         l_record.
    ENDLOOP.
    AT END OF werks.
Close File
      CLOSE DATASET g_file_name.
      CLEAR   g_file_name.
    ENDAT.
  ENDLOOP.
ENDFORM.                    " sub_batch_stock

Similar Messages

  • In LSMW using BAPI Scenario, how to assign the same file to HEADER and ITEM

    Hi,
    i got a problem when we are in ASSIGN FILES step how to assign the same file to both HEADER and ITEM Structures?

    Hi,
    When defining the file in specify files step check the option 'Data for Multiple Source Structures'.
    Hope it helps.
    Thanks,
    Mahesh

  • Joining head- and item- records during data-staging

    Hi experts,
    I've got the following scenario:
    I get data from 2 datasources, one (myds_h) provides documents-heads and the other one provides document-items (myds_i).
    Unfortunately the myds_i-DataSource does not contain the head-fields (but foreign-key-fields with the reference to the head).
    For the reporting I'd like to provide item-level data containing the document-head-information as well.
    Which point of the data-staging in the BW-system would you recommend for doing this join?
    Maybe some options:
    a) I could enhance the myds_i-DataSource and do the join in the source-system.
    b) I could enhance the item-data using the transformation between the item-PSA and an item-ODS.
    c) I could enhance the item-data using a transformation between an item-ODS and an additional item/head-ods
    d) I could enhance the item-data using the transformation between the item-ODS and the final InfoCube.
    e) I could use an Analysis-Process-Chain and an InfoSet instead of the above mentioned transformations.
    Thanks for your comments and input in advance!
    Best regards,
      Marco
    Edited by: Marco Simon on Feb 13, 2012 3:52 PM - inserted one option.

    Hello Marco,
    In your solution a) to d), you will have some delta pb. If header data modification can occur without any modification on the items, you will lose some header modification in your item DSO.
    The easiest solution will probably be to handle the header data as a masterdata (header data as attributes of this masterdata), Header data will then be available with your item data. This solution may cause some performance problem if you have a lot of headers.
    Another solution will be to build a transformation between you header DSO and your item DSO (every header modification will modify all items of the header). This will bring some ABAP
    Regards,
    Fred

  • ERLA/NORM, Header and Item Level Pricing Issue

    Dear All,
    I have an issue wherein, even though I have used ERLA for BoM Item and NORM for Subitems, in sales order Conditions, both header level and item level pricings are active.
    Correct me if I am wrong, item level pricing should get deactivated.
    Kindly let me know if there is any issue in the settings.
    The default item categories appearing in the sales document is TAQ for higher level item and TAE for subitems
    Thanks and Regards
    Adithya
    Edited by: Adi1976 on Feb 6, 2012 12:08 PM

    Item Category group for Subitems should be ERLA, not NORM.
    Sales Order
    - Item Cat Group
    - Higher I Cat
    - I Cat
    OR
    ERLA
    TAQ
    OR
    ERLA
    TAQ
    TAE
    Try & share feedback.
    Regards
    JP

  • File content conversion - sender adapter for Header and detail records

    Hi Experts,
                     I am receiving a field of fixed length content format.(Header)The first line of the file will follow the structure X having some fields and (DetailRecord)subsequent lines in the file will follow structure Y having somes fields.There is no record identifier for Header and Detail records.In one file first line is Header records and remaining subsequent line is DetailRecord.What are the parameters we have to set for sender file content conversion parameters as i donot have any key field and key field value.And in one file we have only one header records ( first line) and n number of detail records from 2nd line onwards.
    Thanks
    Deepak

    Hi
    Refer the below fourm link,
    Flat file whitout id
    Regards
    Ramg.

  • Sender FILE Adapater Content Conversion: Header and Item Data

    Hi
    I need to pick a file and do the content conversion. The XML structure which should be formed should be in the below format. I have a CSV file which needs to be converted.
    Kindly suggest how can I maintain parameters for Header and Item level data in Recordset structure.
    How can I specify in Recordset parameter which is Header(Customerno, Doc type and Address) and Item level(Line Item) data.
      <?xml version="1.0" encoding="UTF-8" ?>
      <customernumber></customernumber>
      <documenttype></documenttype>
    - <Address>
            <name1></name1>
            <name2></name2>
      </Address>
    - <LineItem>
            <material>100016</material>
            <amount>1000</amount>
    </LineItem>

    Hi Swetank,
    The file after conversion should have one Header and you can have any number of line items.
    Once you choose File Content Conversion in the message protocol header while configuring the Sender File Adapter, you get the following enteries in the Content Conversion Parameters:
    Document Name
    Document Namespace
    Document Offset
    Recordset Name
    Recordset Namespace
    Recordset Structure
    Recordsets per Message
    Key Field Name
    To maintain the Header information, Some entries are mandatory, i.e.
    Recordset Name: Here please specify the name of the structure. It is included in the XML schema.
    Recorset Structure: Here you need to enter the sequence and the number of substructures. Since Header is one but you can have many Line items, you will write:
    customernumber,1,documenttype,1,Address,1,LineItem,*
    this format is clearly explained in the link provided by Divya.
    And in the Additional fields you need to write the name of fields corresponding to different Recorset Structures and also add some property to it, like fixed lengths, use some separators etc.
    and Most important field is:
    Key Field Name: If you specified a variable number of substructures for Recordset Structure, in other words, at least one substructure has the value ‘*’, then the substructures must be identified by the parser from their content. This means that a key field must be set with different constants for the substructures. In this case, you must specify a key field and the field name must occur in all substructures.
    Here you need to enter LineItem as it is the only Recordset Structure with an *.
    I hope this solves your problem,
    Thanks and Regards,
    Varun Joshi

  • Checkbox in header and item level records.

    Hello Freinds,
    I have a requirment in which I need to display checkboxes in front of header as well as item level records. I am trying to make a copy of standard transaction VL37. This transaction uses the REUSE_ALV_HIERSEQ_LIST_DISPLAY for displaying header and item level data. I debugged and found that in the alv layout there is a field with name box name. If we pass the name of header internal table to that field then we can get checkbox in front of header level records and if we pass item level internal table name then it shows the checkbox in front of item level records.
    Can anyone provide some possibility of adding checkbox for both header and item level records while using the same ALV FM.

    Hello Harsh,
    I am also kind of facing the same issue. I have used the FM REUSE_ALV_HIERSEQ_LIST_DISPLAY for ALV display. And I need to add checkbox at item level.
    I have tried to add checkbox through field catalog. Following is the code I'm writing.
    l_wa_fieldcat-fieldname = l_c_flag.
    l_wa_fieldcat-tabname   = l_c_item.
    l_wa_fieldcat-checkbox  = abap_true.
    *l_wa_fieldcat-edit_mask = abap_f.
    l_wa_fieldcat-edit      = abap_true.
    l_wa_fieldcat-key       = abap_true.
    l_wa_fieldcat-seltext_m = l_c_flag.
    APPEND l_wa_fieldcat to em_it_fieldcat.
    But in this case the checkbox appears in disabled form.
    Can you please help? Could you be a bit elaborate on your answer i.e. the code snippet? Many thanks.
    Regards,
    Debapriya

  • How to header and item data of sales order using bapi interface

    hi friends,
       i am geetha, i having a problem like how to upload sales oder header and item data through va01 tcode using BAPI FUNCTION MODULES.
    i need bapi function modules for header adn item data  and brief explation on that , how to pass importing and tables  parameters to get exact output .
    regards
    geetha.

    Use : BAPI_SALESORDER_CREATEFROMDAT2
    Sales order: Create Sales Order
    Functionality
    You can use this method to create sales orders.
    You must enter at least sales order header data (via ORDER_HEADER_IN structure) and partner data (via the ORDER_PARTNERS table) as input parameters.
    Enter the item data via the ORDER_ITEMS_IN table. You can allocate item numbers manually, by filling in the relevant fields, or the system does it, according to the settings for Customizing, by leaving the relevant fields blank.
    If you have configurable items, you must enter the configuration data in the ORDER_CFGS_REF, ORDER_CFGS_INST, ORDER_CFGS_PART_OF and ORDER_CFGS_VALUE tables.
    Credit cards can be transferred via the BAPICCARD structure, on the one hand, data for card identification, on the other, data for a transaction which has taken place in an external system.
    Once you have created the sales order successfully, you will receive the document number (SALESDOCUMENT field). Any errors that may occur will be announced via the RETURN parameter.
    If no sales area has been created in the sales order header, then the system creates the sales area from the sold-to party or ship-to party, who has been entered in the partner table. If a clear sales area cannot be created, you will receive a system message, and the sales order will not be created.
    Notes
    1. Mandatory entries:
    ORDER_HEADER_IN : DOC_TYPE     Sales document type
                       SALES_ORG    Sales organization
                       DISTR_CHAN   Distribution channel
                       DIVISION     Division
    ORDER_PARTNERS..: PARTN_ROLE   Partner role, SP sold-to party
                       PARTN_NUMB   Customer number
    ORDER_ITEMS_IN..: MATERIAL     Material number
    2. Ship-to party:
    If no ship-to party is entered, use the following: Ship-to party =
    sold-to party.
    3. Commit control:
    The BAPI does not have a database commit. This means that the relevant application must leave the commit, in order that can be carried out on on the database. The BAPI BAPI_TRANSACTION_COMMIT is available for this.
    4. German key words:
    The following key words must be entered in German, independantly of
    the logon language:
    DOC_TYPE     Sales document type, for example: TA for standard order
    PARTN_ROLE   Partner role, for example: WE for ship-to party
    Further information
    You can find further information in the OSS. The note 93091 contains general information on the BAPIs in SD.
    Parameters
    SALESDOCUMENTIN
    ORDER_HEADER_IN
    ORDER_HEADER_INX
    SENDER
    BINARY_RELATIONSHIPTYPE
    INT_NUMBER_ASSIGNMENT
    BEHAVE_WHEN_ERROR
    LOGIC_SWITCH
    TESTRUN
    CONVERT
    SALESDOCUMENT
    RETURN
    ORDER_ITEMS_IN
    ORDER_ITEMS_INX
    ORDER_PARTNERS
    ORDER_SCHEDULES_IN
    ORDER_SCHEDULES_INX
    ORDER_CONDITIONS_IN
    ORDER_CONDITIONS_INX
    ORDER_CFGS_REF
    ORDER_CFGS_INST
    ORDER_CFGS_PART_OF
    ORDER_CFGS_VALUE
    ORDER_CFGS_BLOB
    ORDER_CFGS_VK
    ORDER_CFGS_REFINST
    ORDER_CCARD
    ORDER_TEXT
    ORDER_KEYS
    EXTENSIONIN
    PARTNERADDRESSES
    Exceptions
    Function Group
    2032

  • Header and item data in LSMW

    How to distinguish between the header and item data from the given legacy excel file, so that I can correctly extract the Sales Order header and item level data while doing LSMW? Do we need to do any extra coding for doing that?

    Hi Diwakar,
    Please read below. This is the way to do it. It resolved my issue.
    Hi, I think you can use 1 file but with the record type identifier, the field will appear in all source strictures, in the Maintain Source Fields step amend field (double click) on it and point Identifying Field Content to appropriate level, e.g. 1 for header 2 for item. Your input file will look like:
    REC_TYPE….. FIELDS
    1 only fields relevant for the header and blanks for line items
    2 only fields relevant for the item data blanks for header fields
    2 …
    2 …
    1 Next record header
    2 next record item 1
    2 next record item 2
    1
    2
    2
    2
    2
    1
    2
    Diwakar,
    Please dont be oversmart and dont mislead people and hurt others by making nasty comments.
    Thanks,
    Raj.

  • PO text(Header and Item) OMQ6 and CG3Y

    Hi All
    We are running Tcode OMQ6 and Then CG3Y to get the text present in header and item level for set of POs. now i have done this for almost 1000 POs out of which for  20-30 POs  syetem is not giving correct result.
    actually for these POs text is present at item level but OMQ6 is not transferring this to loacl file or we can say it is not considering these PO.
    I am wondering what can be the possible reason for this, if anybody have worked on this and got similar issue the appreciate your fast reponse.
    Regards
    Yogesh

    Hi Yogesh,
    this is a long shot, but could it be that the ones that are being missed have been manually entered or changed and the others have been taken from the material or info record? (or vice versa)
    I am not sure which texts you are using, so sorry if this is not relevant.
    remember that when you set up texts to be copied from the material master or info record there are flags that indicate if the text is copied into the PO or simply referenced from the mastr record (in which case you SEE it on the PO but it is actually still stored on the material master or info record).
    As I say, just a long shot, but nothing else springs to mind.
    Steve B

  • How can i create Header and items in SMART FORM

    Hi Experts,
    How can i create Header and items in SMART FORM in the below driver program.
    _Header fields_
    SELECT BUKRS BUDAT GJAHR CPUDT USNAM BLART BELNR XBLNR BLDAT WAERS KURSF
      FROM BKPF INTO CORRESPONDING FIELDS OF TABLE IT_HEAD WHERE BELNR IN S_BELNR AND BUDAT IN S_BUDAT AND GJAHR EQ S_GJAHR AND BUKRS EQ S_BUKRS AND CPUDT IN S_CPUDT AND USNAM IN S_USNAM.
    Item firlds
    SELECT BUZEI BSCHL SGTXT SHKZG KOSTL PRCTR WERKS WRBTR HKONT KUNNR ZFBDT FROM BSEG INTO CORRESPONDING FIELDS OF TABLE IT_ITEM
      FOR ALL ENTRIES IN  IT_HEAD WHERE BELNR = IT_HEAD-BELNR AND GJAHR = IT_HEAD-GJAHR AND BUKRS = IT_HEAD-BUKRS.
      LOOP AT IT_HEAD.
    MOVE-CORRESPONDING IT_HEAD TO FINAL.
        LOOP AT IT_ITEM
        WHERE BELNR = IT_HEAD-BELNR.
          MOVE-CORRESPONDING IT_ITEM TO FINAL.
    ENDLOOP.
    ENDLOOP.
    Regards,
    Sreedhar.

    for these internal tables you can pass some Identifier  for both tables.
    in header file : IT_HEAD
    IDENT   type  char10,
    BUKRS type BUKRS,
    BUDAT type BUDAT,  like
    in header file :IT_ITEM
    IDENT   type  char10,
    BUZEI type BUZEI,
    BSCHL type BSCHL,  like  in item data
    you need to fille the  IDENT value like
    IT_HEAD:
    10 -- DE01-- 10.20.2009
    20 -- CH01-- 10.20.2009
    IT_ITEM
    10 -- 1234-- KSCHL value  like all records
    10 -- 2345-- KSCHL value  like all records
    10 -- 6783-- KSCHL value  like all records
    20 -- 3452-- 1KSCHL value  like all records
    20 -- 4532-- KSCHL value  like all records
    20 -- 4535-- KSCHL value  like all records
    in smartform you need to create 2 tables.
    or create
    LOOP  with IT_HEAD
    table with IT_HEAD
    table with IT_ITEM
    and put the condition for each table in  DATA tab where condtion  like IDENT = IT_HEAD-IDENT
    in item table also INDENT = IT_ITEM-INDENT..

  • How to get header and item data in ME_PROCESS_PO_CUST ?

    Hi all,
    How can I get header and item data in me_process_po_cust~process_account ? I have to do some validation for account assignment catagory in item overview.

    Hi ,,
    Further make the following  changes in method IF_EX_ME_PROCESS_REQ_CUST~PROCESS_ITEM.
    Get Line item data using method:
    CALL METHOD IM_ITEM->GET_DATA    
      RECEIVING
          RE_DATA = W_ITM_DATA.
    and then validate the item data from structure  W_ITM_DATA..
    Same as follows for Header Records:
    In method IF_EX_ME_PROCESS_REQ_CUST~PROCESS_Header.
    Thanks
    Shambhu

  • Open Hub Header and Trailer Record.

    Hi,
    For the Open Hub Destination
    Destination Type is File,
    Application server.
    Type of File Name: 2 Logical File name.
    How to to the get the Header and Trailer Record which will contain Creation Date, Creation Time and Total number of records.
    Header record Layput :
    Creation Date (YYYYMMDD)
    Creation Time (HHMMSS)
    Total record Count
    Trailer record Layout:
    Total number of Records in the file and
    XXXX( Key Figure ) Total.
    Thanks in advance.
    Regards,
    Adhvi.

    Hi Venkat,
    write a UDF in following way...
    pass the first parameter as the detail node (cache the whole queue) to the UDF pass the second parameter as the trailer countto the UDF
    now loop through the detail records get the count with a counter variable
    check the counter against the trailer count outside the loop
    if it doesnot match trigger the alert from the UDF itself
    Check the below link for triggering alert from an UDF
    /people/bhavesh.kantilal/blog/2006/07/25/triggering-xi-alerts-from-a-user-defined-function

  • Transaction to Mass Update Header and Item text in Purchase Order

    Dear All
    Whether any Transaction in SAP to mass update the Header and Item text in Purchase Order.
    One Single Text For Ex :" This is a Dummy PO" .
    This text needs to be updated in large number of POs.
    Please let me know your views
    Reg
    Shyam

    Hi Shyam,
    You can make use of BAPI_PO_CHANGE for this. See the documentation of this BAPI in SE37 for more information.
    "You can transfer header and item texts in the PoTextHeader and PoTextItem tables. You import texts
    for services in the PoServicesText table. Texts can only be replaced complete."
    Regards,
    Purnima.

  • Header and Item table - Form Design Question

    Hi All,
    I have a header table and Item table. For every record in the header table I have multiple records in the item table. I want to have a adobe form in the following way
    1. A new page starts for every record in the header table and Items in the item table for this header record can span multiple pages with the same header information.
    2. When all the items are displayed for that particular header record, a new page should start for the next header record.
    I created one internal table in the following way
    Header_field1 Header_field2 Item_table(with all the items for this header record)
    Header_field1 Header_field2 Item_table(with all the items for this header record)
    I am not sure how to use a table for this scenario (Should It be a nested table?).
    Please provide me some ideas.
    Thanks,
    Ganesh.

    Hi Balasubramani,
    I made some changes and have the following now. Can you please let me know how I can achieve page break for every BP_NUMBER.
    I have a nested table like the one below.
    Main table u2013 Has header and Items information. Every header record has some header information like BP number, name and all line items for that BP in a nested table .
    IT_HEADER:
    BP_NUMBER     BP_NAME           IT_ITEMS(Items table)
    BP_NUMBER     BP_NAME           IT_ITEMS
    BP_NUMBER     BP_NAME           IT_ITEMS
    To display this information I created the following
    Subform1 u2013 overflow u2013bound to $record.IT_HEADER.DATA[*] u2013 (Repeat sub form for
    |                                             each data item)
    |->Header sub form u2013 Positioned
    |     |
    |     |-> Text Field u2013 bound to BP_NUMBER
    |
    |
    |->Item sub form -
         |     
         |->Item Table u2013 bound to IT_ITEMS
              |
              |->Data u2013 bound to IT_ITEMS.DATA[*] u2013(Repeat row for each data item)
    In the output BP number in the first record of IT_HEADER gets displayed and then all the Item records in IT_ITEMS for that BP get displayed. This is repeated all the records in IT_HEADER which is perfectly fine.
    Please provide me some suggestions to solve the following issues I am having
    1.     I need a page break between records of IT_HEADER. I want the new subform1 for the next header record to start in a new page. I tried conditional break option, on the only field BP number in header sub form. I have two master pages and two body pages. All the above information is in master page 2 and body page 2.  I am also not sure what to select in the TO section of the conditional break screen.
    2.     When there is an overflow in IT_ITEMS I need the Header sub form to be shown in the next page too.
    Thanks,
    Ganesh.

Maybe you are looking for

  • Incorrect trapping of free space in tablespace

    Hi, We have a script that monitors tablespaces, and flags if they are getting full. The code is shown below...... select tablespace_name from (select a.tablespace_name, a.physsp/1024/1024 psm, nvl(b.freesp,0)/1024/1024 fsm, nvl(b.mfreecnk,0)/1024/102

  • Nokia 5800 31.0.008 CALL BUG

    Hi! Also with this firmware, occasionally, phone crash (freeze and reboot) during a call, when H3G netwok (3 Italy) is missed (0 antenna signal). In Italy, when H3G network (HSDPA, UMTS) is unavailable, the operator switch automatically in roaming mo

  • Claim Payment

    Dear All,               I've created internal Claim by CL01 and assign this claim to WBS Element.And Cost Collector is also greated.I've approved this clim and internal order is also created .                                                          

  • Convert from Entourage - Arrows don't show for replies or forwards

    I'm using Entourage 2004, and OS X 10.4.6 I recently converted from Entourage to Mail, but none of my messages which I had replied to or forwarded show as such. The column is turned on, and any new messages that I reply to do show the arrow in that c

  • Time estimation for WebDynpro component

    Hi all, I am very new to WDA. If any body have idea about time estimation for ABAP webDynpro component based on complexity, please let me know. Format of writing technical spec for WDA component? Thanks in advance Regards, Rajesh yadla.