Last Line Item in Report Repeating on Next Page

The last line of data of every page is also the first line on the next page. I have not encountered this before and I cannot see how it is happening or how to correct it.
The report has three groups and the 3rd group has 3 details lines. It is the 2nd detail line that repeats. The repeating line has not encountered a group change, nor has the 3rd detail line been triggered. It is a simple report that lists a line of data and prints it onto the report.
The SQL is grouped by the same grouping of the report. Yes, data does repeat in the SQL, which would be expected for the  grouping. However, the data does not repeat in a group of the data returned by the SQL statement, so there is no reason for this data repetition.
It is not restricted to any one piece of data in the report. The line that repeats is the last line on a page. Clicking on the next page of the report shows the last line of the previous page is the first line of the new page. This is true whether the report is viewed or printed.
Does anybody have any suggestions?
Thank you.

I was able to resolve this. The detail section did not have the Keep Together checked. Once this was checked, the repeating line issue was resolved.

Similar Messages

  • Line items are not coming on next page in Bill of Lading

    When I am printing Bill of Lading, if it has around 8 line items then its printing on the first page, but if line items are more then its not printing the remaining line items on second page.
    I have one delivery with 10 line items, when I am printing it then on first page 7 line items are coming and for 8 line item only material is printing and on second page its description is printing but last two line items are not printing at all.
    Kindly help me to resolve the issue as it is very critical.

    Hi,
    Check below points.
    Point 1:
    When you create a delivery document, you create it for a Shipping Point.
    So whatever the line that came in to one delivery has determined same shipping point that you entered in VL01N screen.
    Others got a different shipping point and that's why it didn't come to the same delivery document.
    Shipping point determined based on below criteria
    - Shipping Condition - From customer master
    - Loading Group - Material
    - Plant  - Delivery Plant of the sales order line item
    You assign a proffered shipping point for above combination in configuration.
    If that combination is not find, those line items are not going in to the delivery.
    You can check the log of the delivery document for more information as well.
    Point 2:
    Check the line item Requested delivery date and the "Selection Date" you entered in the VL01N screen.
    Al  Requested delivery dates has to be on or before the  "Selection Date" you entered in the VL01N screen.
    Those line items which has a date more than that will dropped in the delivery.
    Best regards,
    Anupa

  • Display line items of the data into next page in case of overflow

    Hi all,
    In my requirement i am displaying header data with its line items  through smart forms ( Landscape format).Since i am using landscape format main window size is less.Hence, In case of overflow of data
    the line items only should get displayed in the next page without the header information.
    I have given next page as Second page and i kept only  main window in the next page. But still it is displaying header information in the next page in case of overflow of data.
    Thanks in Advance
    Regards,
    Bhanu.R

    Hi Bhanu,
    In this case you can go for any one of the below 2 solutions.
    1) Try to use a seperate window(secondary window) for header information and for line items use main window. In second page use only main window. So, when the data overflows you will get only the line items.
    2) Try to use text elements. Give the header information in one text element say T1 and the line items in another text element say T2. And then write WRITE_FORM for text element T2 in a loop to display the line items.
    Hope this will help you.

  • Final total cannot appear when the last line item reached the page end

    Hi All,
    My report included 2 pages. Problem is the final total cannot appear when the last line item reached the page end. (page 2)
    final total will appear on the middle of last page (page 3) when i comment (type    = 'BOTTOM').
    Below is the program.
      CALL FUNCTION 'OPEN_FORM'
        EXPORTING
          device   = 'PRINTER'
          dialog   = 'X'
          form     = 'ZBOTM_VOUCHER'
          language = sy-langu.
      sort itab by vblnr.
      LOOP AT itab INTO wa_itab.
        move wa_itab-vblnr to reguh-vblnr.
        move wa_itab-lifnr to reguh-lifnr.
        move wa_itab-rbetr to reguh-rbetr.
        reguh-rbetr = reguh-rbetr * -1.
        CALL FUNCTION 'WRITE_FORM'
          EXPORTING
            window  = 'MAIN'
            element = 'DETAIL'.
        t_rbetr = reguh-rbetr + t_rbetr.
        AT LAST.
          CALL FUNCTION 'WRITE_FORM'
            EXPORTING
              window = 'LINE'.
          CALL FUNCTION 'WRITE_FORM'
            EXPORTING
              element = 'TOTAL'.
              type    = 'BOTTOM'
              WINDOW  = 'MAIN'.
        ENDAT.
    Thanks.

    Hi,
    Where should I include the code for bottom?
    How to open text editor?
    Thanks.
    Edited by: Alice8 on Feb 7, 2011 9:09 AM

  • Printing in only last line item printing in main window

    Hi All,
    My requiremnet is to print same data in two blocks for F110 payment cheque
    Iam using 2 main windows to print same data if block exceeds it will go to next page
    iam calling the windows as shown below
    CALL FUNCTION 'WRITE_FORM'
          EXPORTING
            window   = 'MAIN00'
            element  = hlp_ep_element
            function = 'APPEND'
          EXCEPTIONS
            window   = 1
            element  = 2.
        IF sy-subrc EQ 2.
          err_element-fname = t042e-zforn.
          err_element-fenst = 'MAIN00'.
          err_element-elemt = hlp_ep_element.
          err_element-text  = text_525.
          COLLECT err_element.
        ENDIF.
        CALL FUNCTION 'WRITE_FORM'
          EXPORTING
            window   = 'MAIN01'
            element  = hlp_ep_element
            function = 'APPEND'
          EXCEPTIONS
            window   = 1
            element  = 2.
        IF sy-subrc EQ 2.
          err_element-fname = t042e-zforn.
          err_element-fenst = 'MAIN01'.
          err_element-elemt = hlp_ep_element.
          err_element-text  = text_525.
          COLLECT err_element.
        ENDIF.
    Iam getting only last line item printing in main window
    Please provide the inputs.
    Thanks,
    Kamalakar.
    Please use code tags.
    Edited by: Rob Burbank on Nov 25, 2011 11:51 AM

    Hi,
    My requirement was to print same block twice in cheque printing of F110.
    I have used the function module  'WRITE_FORM_LINES' to print more than one line item in secondary window in the script .
    fill the Lines internal table as shown below.
    Example :
        lines-tdformat = 'TM'.
        CONCATENATE regup-xblnr ',,' w_date ',,'  w_bsak-sgtxt ',,' w_gross ',,' w_dis ',,'
        w_net INTO lines-tdline.
    APPEND lines.
    CALL FUNCTION 'WRITE_FORM_LINES'
          EXPORTING
           function                       = 'APPEND'
           header                         =  header_t
           type                           = 'BODY'
           window                         = 'MAIN01'
        IMPORTING
          FROMPAGE                       =
          PENDING_LINES                  =
          TABLES
            lines                          = lines
         EXCEPTIONS
           function                       = 1
           type                           = 2
           unopened                       = 3
           unstarted                      = 4
           window                         = 5
           bad_pageformat_for_print       = 6
           spool_error                    = 7
           codepage                       = 8
           OTHERS                         = 9
        IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
        ENDIF.
      ENDIF.

  • Capture last line item

    I have a requirement where in i have to display a pop up with all the line items given by user in ME21N . The pop up has to display when user presses CHECK .
    I written the code in the exit EXIT_SAPMM06E_017 . its working fine for single line item.
    In case of multiple line items the popup appears for every line item instead of showing all the line items in a single pop up since in the user exit there is no provision of capturing the LAST LINE ITEM . The field EKKO-LPONR which captures the last line item , is populated only after the exit is triggered which captures the value of EKPO-EBELP( line-item). I manage to capture the line items in internal table but unable to capture last line item and then display the internal table in pop up .
    If the user gives two line items say 10 , 20 .
    Line item 10 is populated to field EKPO-EBELP . After the control comes out of the exit the value of EBELP is assigned to LPONR . At next control LPONR = 10 and EBELP = 20.
    Thanks .

    Hi Priya,
    To show popup for the last line item, try with this logic:
    You have an internal table with all line items, take an internal table with same structure. Take the number of lines and read the line iten into work area and append this work area into another table. after that read this second internal table with EBELN and EBELP, if it is matching then show the popup for all line items from first internal table.
    Put this code:
    <b>dsescribe int_first into ws_lines.
    if ws_lines gt 0.
    read table int_first into wa_first index ws_lines.
    if sy-subrc eq 0.
      append wa_first to int_second.
    endif.
    endif.
    if not int_second is initial.
    read int_second into wa_first with key EBELN = 'structure ebeln value'
                                                            EBELP = 'structure ebelp value'
      if sy-subrc eq 0.
       " put POPUP code
      endif.
    endif.</b>
    Hope it will solve ur problem.

  • Line item actuals report for Profit center group

    I am looking for a Line Item Actuals report for a Profit Center Group  on the lines of KSB 1 report for Cost center /groups.
    I tried report "KE5Z but only profit centers can be selected, not profit center groups.
    Any help on this

    Try out the following report
    S_ALR_87013326 - Profit Center Group: Plan/Actual/Variance
    Call up Actual line items, here we go you would get the profit center group reports in similar lines as KSB1.
    Award points so as to say thanks.
    Regards,
    Suraj

  • Cumulative GL Line Item Balance Report

    Hi,
    Can anybody suggest Cumulative GL Line Item Balance Report in SAP.
    thanks in advance
    Muhammed Riyas

    Hi Ryas,
    This means you are looking for a report of GL Account Statement, where you can have all GL Line item (documents) and thier total also,
    You can use S_ALR_87012332 report, you can also add column total debit and total credit column, then sum of all the line item you can see against each gl, please see below output snapshot.
    Regards
    Javed

  • Only the last line item is shown in main window...

    Hello Experts,
    I created a custom form for the standard checque program RFFOUS_C. Now, in my MAIN window, I
    called a subroutine in a custom program which loops through the line items but the problem is
    only the last line item is being shown. I tried using CONTROL_FORM to create a new line
    but it does not work. Note that I did not customize RFFOUS_C since it is being used by
    multiple companies. Below is my code:
    SAPSCRIPT:
    510-C
    Begin of insertion DEVK940799 11/10/2008 DEL_HIDALGO
    DEFINE &LTYC_XBLNR& = ''
    DEFINE &LTYC_BLDAT& = ''
    DEFINE &LTYC_SGTXT& = ''
    DEFINE &LTYC_DMBTR& = ''
    PERFORM WRITE_LINE_ITEMS IN PROGRAM Z9999RFI_Z2574FFI_RA
    USING &REGUH-LAUFD&
    USING &REGUH-LAUFI&
    USING &REGUH-XVORL&
    USING &REGUH-ZBUKR&
    USING &REGUH-LIFNR&
    USING &REGUH-VBLNR&
    CHANGING &LTYC_XBLNR&
    CHANGING &LTYC_BLDAT&
    CHANGING &LTYC_SGTXT&
    CHANGING &LTYC_DMBTR&
    ENDPERFORM
    PROTECT
         &LTYC_XBLNR&     &LTYC_BLDAT&     &LTYC_SGTXT&     &LTYC_DMBTR&
    ENDPROTECT
    End of insertion DEVK940799 11/10/2008 DEL_HIDALGO
    PROGRAM:
    IF gt_regup[] IS NOT INITIAL.
        CALL FUNCTION 'OPEN_FORM'
           EXPORTING
    *         APPLICATION                       = 'TX'
    *         ARCHIVE_INDEX                     =
    *         ARCHIVE_PARAMS                    =
    *         DEVICE                            = 'PRINTER'
    *         DIALOG                            = 'X'
             form                              = lcc_z2574ffi_ra
    *         LANGUAGE                          = SY-LANGU
    *         OPTIONS                           =
    *         MAIL_SENDER                       =
    *         MAIL_RECIPIENT                    =
    *         MAIL_APPL_OBJECT                  =
    *         RAW_DATA_INTERFACE                = '*'
    *         SPONUMIV                          =
    *       IMPORTING
    *         LANGUAGE                          =
    *         NEW_ARCHIVE_PARAMS                =
    *         RESULT                            =
           EXCEPTIONS
             canceled                          = 1
             device                            = 2
             form                              = 3
             OPTIONS                           = 4
             unclosed                          = 5
             mail_options                      = 6
             archive_error                     = 7
             invalid_fax_number                = 8
             more_params_needed_in_batch       = 9
             spool_error                       = 10
             codepage                          = 11
             OTHERS                            = 12.
        IF sy-subrc <> 0.
    *        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    *                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
        ENDIF.
        LOOP AT gt_regup INTO lw_regup.
          m_line_items 'LTYC_XBLNR' lw_regup-xblnr.
          m_line_items 'LTYC_BLDAT' lw_regup-bldat.
          m_line_items 'LTYC_SGTXT' lw_regup-sgtxt.
          m_line_items 'LTYC_DMBTR' lw_regup-dmbtr.
          DELETE ex_output WHERE value IS INITIAL.
          CALL FUNCTION 'WRITE_FORM'
           EXPORTING
             element                        = '510-C'
             function                       = 'APPEND'
    *         TYPE                           = 'BODY'
             window                         = 'MAIN'
    *       IMPORTING
    *         PENDING_LINES                  =
           EXCEPTIONS
             element                        = 1
             function                       = 2
             type                           = 3
             unopened                       = 4
             unstarted                      = 5
             window                         = 6
             bad_pageformat_for_print       = 7
             spool_error                    = 8
             codepage                       = 9
             OTHERS                         = 10.
          IF sy-subrc <> 0.
    *        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    *                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
          ENDIF.
          CALL FUNCTION 'CONTROL_FORM'
            EXPORTING
              command   = 'NEW-LINE'
            EXCEPTIONS
              unopened  = 1
              unstarted = 2
              OTHERS    = 3.
          IF sy-subrc <> 0.
    *        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    *                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
          ENDIF.
        ENDLOOP.
        CALL FUNCTION 'CLOSE_FORM'
    *       IMPORTING
    *         RESULT                         =
    *         RDI_RESULT                     =
    *       TABLES
    *         OTFDATA                        =
           EXCEPTIONS
             unopened                       = 1
             bad_pageformat_for_print       = 2
             send_error                     = 3
             spool_error                    = 4
             codepage                       = 5
             OTHERS                         = 6.
        IF sy-subrc <> 0.
    *        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    *                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
        ENDIF.
      ENDIF.

    Hi,
    Write the at last event in the program and check if it works
      At last.
           CALL FUNCTION 'CONTROL_FORM'
            EXPORTING
              command   = 'NEW-LINE'
            EXCEPTIONS
              unopened  = 1
              unstarted = 2
              OTHERS    = 3.
          IF sy-subrc  0.
           MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                   WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
          ENDIF.
    Regards,
    Sravanthi

  • COPA Realignments for line item based reports

    Hi Guru
    I built two CO-PA  line item based reports in our environment. Now , there are some organizational changes in our environment and Now I have re-derive a characteristic from customer master data. Does those changes reflect in my line item based reports, If i run Re-Alignments (KEND)?
    Thanks in advance

    Line item reports (defined w/KE91) will reflect the realignment.  Line item display (KE24/KE25) will give you the choice of reading the original posting or the realigned data.

  • Select last line item from VBAP

    Dear SAP experts,
    This might sound very silly question but I am new to SAP world.
    is there a simple select statement to select only higest line item.
    Say for example in VBAP, I have 9 line items.
    then my select statement should find the last line item. ie. 9th item.
    Actually, I have a situation where a custom table has 2 key fields and I want to select the only 1 line with higest number in 2nr column. Thank you.
    Anitha.

    Hi,
    types: BEGIN OF ls_vbap,
             vbeln TYPE vbap-vbeln,
             posnr TYPE vbap-posnr,
           END OF ls_vbap.
    DATA : t_vbap TYPE STANDARD TABLE OF vbap WITH HEADER LINE,
           wa_vbap type ls_vbap.
    data: lv_line type int4.
    SELECT vbeln posnr FROM kna1 INTO TABLE t_vbap.
    *****If you just need the last record then write the code  as shown below:
    DESCRIBE TABLE t_vbap LINES lv_line.
    READ TABLE t_vbap INTO wa_vbap INDEX lv_line.
    if sy-subrc = 0.
    write:/ wa_vbap-vbeln.
    endif.
    If you the need the last record after sorting then use the below code:
    SORT t_vbap by vbeln posnr DESCENDING.
    READ TABLE t_vbap into wa_vbap index 1.
    if sy-subrc = 0.
    write:/ wa_vbap-vbeln.
    endif.

  • Fields only to be displayed for last line item

    I copied WESCHEINVERS3( goods receipt form) script to zxxxx and placed some fields  in Main window using Perform statement. When i am displaying the output these fields are getting displayed under each line item. but i want them to be displayed under last line item.Please suggest how can i do this.
    Thanks
    K Srinivas

    data: v_cnt1 type i, v_cnt2 type i.
    count the number line item using describe lines statement in V_cnt1
    and in the table loop count the number of item into V_cnt2.
    place the field that you want at the end of all line item in the footer of the table and put  a condition in the condition tab v_cnt1 = v_cnt2.

  • Smartforms: no page break between last line item and footer in table?

    Hello All,
    my smartform has FIRST and NEXT pages. I would like to avoid a page break between last item line of a table in MAIN window and the footer of the same table.
    Here is how it looks currently.
    Output of FIRST page, MAIN window, table ITEMS:
    1.line item
    2.line item
    3.line item
    4.line item
    page break
    output of NEXT page, MAIN window, table ITEMS:
    1.footer line
    2.footer line
    I would like that if a footer does not fit on FIRST page, it would be displayed on NEXT page with last item line.
    It should be like this:
    output of FIRST page, MAIN window, table ITEMS
    1.line item
    2.line item
    3.line item
    page break
    output of NEXT page, MAIN window, table ITEMS
    4.line item
    1.footer line
    2.footer line
    Any ideas?
    Thanks and best regards,
    Mindaugas

    Do you mean line item text or your want to print footer text?
    If your trying yo display some footer text, then you either place a footer window or you can create a table inside your main window and place text under the footer of the table, then it will display the text without any page break.
    If it is item tem.
    Then you need to build additional logic. As we cannot guess, the total number of item text upfront.
    Example: if page1 can hold 15 line items, check whether your header and item can fit in page one else call a new page by placing a condition FLAG = "X".
    I hope it will help you to solve your problem.
    Regards,
    SaiRam

  • Expense (PR05) - Line item change report

    Hi:
    We are looking for a report on the changes made in the trip line items after the trip was submitted, approved, transferred to FI (at every status).
    Basically if a consultant has submitted an expense and is approved by the manager, Then if consultant is opening that trip again and making the changes in the line item (change in cost object, amount etc) or adding a new line, we need  a report which tells when was the change made, what was the change etc.
    With the custom program, we are able to get the trip status history but not the line item details (change).
    Any suggestions.

    It tells the status of the trip but doesn't tell me what change is made.
    For example:
    If the original trip had one line for Airfare (say 1000) which was approved and transferred.
    Later on this was adjusted to Airfare (say 1010) which was again approved.
    We want to know amount was changed from 1000 to 1010 on this date. Similarly to cost assignment. Any field which has accounting effect.
    Basically our Accounts payable needs to know if they should settle the expenses without waiting for the receipts at month end (in the scenario where cost object is changed later but amount is same, so there is no revised receipt from consultant. They can just settle it again)
    Some kind of report which tells when and what change was made (at item level).
    Thanks.
    Rahul

  • Asset field blank in FS10N (Drilldown to line item level) report layout

    Hi all,
    i ahve posted a Retirement transaction to an asset and when i went to see the line item on the GL using/executing report FS10N for asset transactions GL and drill down to the line item level by double clicking on the period balances and I choose field "Asset" to be displayed in the layout, it is blank. How can I get report FS10N to display the asset number from the transaction?
    the field is available in the layout but when i pull it into the report it is Blank in the report.
    Any help would be appreciated. Thanks
    Jay

    Hello,
    FS10N shows only balance, FBL3N shows the line details.
    Add the asset as a special field via OBVU  (Table:  BSEG, Field: ANLN1).
    Regards
    Waza

Maybe you are looking for

  • Short dump in Z transaction code

    Hi, We have a Z transaction code 'ZPROFIT' for a report. After executing the report from output screen of report if i type 'se38' in command bar and if I press enter key it is going to short dump. But if I type '/nse38' it is working fine.The short d

  • VoiceOver with iTunes 64 bit on Windows 7 64 bit problem

    Is anyone using VoiceOver with iTunes 64 bit on Windows 7 64 bit? We cannot get it to work. I have followed Apple's guideance and uninstalled/reinstalled iTunes and the .dll has been moved from the root directory of C: to the iTunes program directory

  • Has anyone discovered a network error when trying to post or contribute to discussion?

    I have created many courses. The latest one however, I find that I can no longer take part in discussions in any way. I am the owner of the course and other teachers contributing have been able to work normally. I get a network error. I can still add

  • Data are not showing in a Jsp using link

    i have a Jsp page. in this Jsp page having some links. i want when i click to link of result some data should be display. but it does not displaying. please check the below code. Indus.jsp <html> <head> <title>Indus Public School</title> </head> <bod

  • Extra White Space from Hidden Menu Bar

    This seems to be a problem introduced by LV 2013. I have a VI that runs with the menu bar hidden. When I hit ctrl-m to see how it looks in run mode, it looks fine. When I run the VI, instead of fully hiding the menu bar, it leaves white space. This o