Skip to Content
-5

To display two reports in one report?

Hello All,
My requirement is,

if user gives data of cc and execute. the cc report will display. which was working fine. as shown in below figure.

if user gives data of WBS and execute, the WBS report will display. which was working fine. as shown in below figure.

if user gives data of cc and wbs execute. the cc and bs report will display. which was working fine. as shown in below figure.

For cc and wbs report im not able to display multiple records.
Because cc and wbs don't have common element to display multiple records.
For which i'm using index 1. So it was not displaying multiple records.
Is there any logic to display multiple records, if yes suggest me how.
I'm searching for past 10 days, but no result.

Please help me out in this.

Below is logic i wrote to display multiple records.

    READ TABLE it_final_cc INTO wa_final_cc INDEX 1.
    MOVE wa_final_cc-kostl TO wa_final-kostl.
    MOVE wa_final_cc-ktext TO wa_final-ktext.
    MOVE wa_final_cc-actual TO wa_final-actual_cc.
    MOVE wa_final_cc-budget TO wa_final-budget_cc.
    MOVE wa_final_cc-commit TO wa_final-commit_cc.
    MOVE wa_final_cc-allot TO wa_final-allot_cc.
    MOVE wa_final_cc-avail TO wa_final-avail_cc.

    READ TABLE it_final_wbs INTO wa_final_wbs INDEX 1.
    MOVE wa_final_wbs-pspnr TO wa_final-pspnr.
    MOVE wa_final_wbs-post1 TO wa_final-post1.
    MOVE wa_final_wbs-actual TO wa_final-actual_wbs.
    MOVE wa_final_wbs-budget TO wa_final-budget_wbs.
    MOVE wa_final_wbs-commit TO wa_final-commit_wbs.
    MOVE wa_final_wbs-allot TO wa_final-allot_wbs.
    MOVE wa_final_wbs-avail TO wa_final-avail_wbs.
    APPEND wa_final TO it_final.
    CLEAR : wa_final.
  ENDIF.
cc.jpg (21.5 kB)
cc-report.jpg (35.4 kB)
wbs.jpg (21.7 kB)
wbs-report.jpg (88.7 kB)
cc-and-wbs.jpg (25.0 kB)
Add comment
10|10000 characters needed characters exceeded

  • Just to be clear: do you want cost center data and wbs data which are not related to appear on 1 line in your output, and then do a (as we in the old days used to refer to) "level break" approach to print both internal tables?

    So CC table contains 10 records, wbs table contains 8 records. This results in 10 lines in the output with on line 9 and 10 only the CC info. Is that what you are after?

  • I displayed two reports using DO and ENDDO Loop.

  • Get RSS Feed

1 Answer

  • Jun 07, 2018 at 09:51 AM

    Hi harish,

    check your third select query "where" condition ,

    if you are using cc and wbs ,, use "or" condition between them.

    Add comment
    10|10000 characters needed characters exceeded