Count of Items in BEx Report

Dear Experts,
We have a report that contains item level data (multiple records for same item in the report). We would like to see the count of records for these items based on aggregation levels.
Since the data is on item level, we have same items available in multiple lines that gives me wrong results.
For e.g, I'd like to see the report that shows the count of items based on some fields like below.
Region
Count of Items
ELAT
20
AMEA
40
NAM
38
So, if I drill down on Sub-region level, I should get the proper count of items as below.
Region
Sub region
Count of Items
ELAT
ER1
10
ELAT
ER2
5
ELAT
ER3
5
AMEA
AR1
40
NAM
NR1
10
MAN
NR2
28
So, the count is same for the above report with additional drill down on Sub region.
When I use Exception Aggregation based on reference characteristic, I'm getting results, but, it varies on different aggregation levels (drill downs of other characteristics).
When I use formula to show '1' for each record, the aggregation shows wrong values, because of multiple records with same item numbers in the report.
I'm not sure Constant Selection would help me because, these are item level data.
Any idea on how to achieve this is much appreciated.
Let me know for any clarifications.
Br, Harish

Hi Yasemin ULUTURK,
I have a similar requirement in which I need to get a count of RKFs in the report.
This RKF is a subset of items count that was formulated earlier using your approach.
Since the count is a formula, I cannot use this for creating an RKF based on it.
Any idea on how to achieve this is highly helpful.
Br, Harish

Similar Messages

  • Count of items in ALV report

    Hi I have created an ALV report  on which i need  a count of number of lines after the sorting  and a grand total count .
    I dont need a total value of the fields but instead a count of number of lines .
    I have sorted by state ALV and then by the facility.I need a count of the number of lines for each facility and then for each region and then a grand count .
    I am using the function  REUSE_ALV_GRID_DISPLAY to display the ALV I am using the is_sort paramater to sort the ALV by the State and facility .
    What parameter do i use to give a count and a grabd count of all items

    Hi Anjali,
    Use this code, while defining the field catalog to hide the individual entries:-
    wa_field-no_out = 'X'.
    append wa_field to it_field.
    And pass this it_field in the FM for ALV Display.
    Hope this solves your problem.
    Thanks & Regards,
    Tarun Gambhir

  • BEx Report Performance with selection-screen input

    Hello Gurus,
    My Bex report is working fine when the report had run with out PLANT filter in the selection-screen but when report had run with plant in the selection-screen , report running for forever.
    Please let me know what I need to do improve the performance.
    Saleem.

    Hi Saleem, Just a few thoughts;
    1. Check the M-table in RSD1 for 0PLANT. In Table View edit any blank or null values. Run the same restrictions you apply in the query at Info provider level > Display Data. If there's any lapse; you can judge where exactly the problem lies.
    2. If you are using Infocube & that your master is >20% fact; you can declare the Info object as 'Line Item Dimension'.
    3. Create Variants. Esp. if you are running the query for same set of data. Try Variable Preselection: You can restrict both the values + varaiables in the filter level. When you execute the values will be visibly pre-selected in selection screen.
    4. As discussed in previous messages, running a SQL trace using RSRT may prove useful.

  • Bex Report Performance

    Dear Friends,
    I would like to know is the complex authorizations can also cause the Bex report performance.
    One of my scenerio is like there are two users A & B
    A is having relevant authorizations for reporting, Drill down etc which are required.
    B is having SAP All authorization.
    When the same report has been executed by both users on the same system.
    the data retrieved by user B(SAP_ALL authorization) is quite faster than User A.
    Its like ther diffference of about 10 minutes.
    There are some exsclude selections in report.
    So my conclusion is like the complex authorizations do also hampers the query performance.
    Please confirm & share your views.
    Thanks & Best Regards,
    Vivek Tripathi
    +91-9372313000

    Hi Vivek
         Can you help us understand what was the exact problem and how you resolved it / solution at Extraction / Modeling / Reporting end.
         I have a quite similiar issue with my report i have Header + Item report on Infoset
    u2022     Header report takes seconds and item report takes minutes
    u2022     The same report executed with exact parameter has inconsistent performance results meaning one time it takes 1 minutes next time same report same user and same authorization takes 5 minutes.
        Any help on this would be really greatfull. Suspecting is not an issue with the report at all , as no changes happened between the pre and post check.
    _Additional Information : _
    We Create Secondary -Bitmap index every week end i do not see that is one of the route cause.
    Except that we have our regular daily loads that are running for master data loads and transaction data loads in series.
       Thanks in Advance.
    Much Regards
    Jagadish Thirumalachetty.
    Edited by: Jagadish Thirumalachetty on Jul 14, 2010 1:35 PM

  • GR and IR as separate columns in the BEx report

    Hi,
    I am working on a Purchasing report in which the user needs the snap shot of PO history,Like PO no.,Item,Netprice,PO Qty,Net order value,GR no.,IR number etc.
    I created a view on EKPO and EKBE.Here,based on the BELNR(Material document) field we are taking GR and IR values.(When VGABE =1 BELNR=GR and VGABE = 2 BELNR=IR).I created DSO to load the data.The problem is they need the GR and IR as separate columns in the BEx report.Could u please help me how to achieve this in BI?
    Thanks & Regards,
    Dinakar.

    Hi Neel,
    I need the BELNR has to be split into GR No.and IR No. separately based on VGABE field.
    Thanks & Regards,
    Dinakar.

  • BEx report : Time diff HH:MM average Issue

    Hello Guys
    below is my Issue with BEx report.
    I have a table with has d1 and d2 and t1 and t2.
    I want the diff between them in only HH:MM, using any of the function modules.
    I have got the HH:HH value into my DSO.
    Then I converted the HH:HH into HH:MM in the BEx.
    Now my report requirement.
    I want to display the report with yearly , monthly and daily information -
    let say my boss wants to compare Average time ( HH:MM) between June and July of 2007.
    the report should be
    year ++++++++ month ++++++ daily ++++++++ rec#++++++++ diff
    2007++++++++ June++++++++ 01++++++++ 123++++++++ 31.36
    2007++++++++ June++++++++ 01++++++++ 124++++++++ 11.23
    2007++++++++ June ++++++++ 03 ++++++++ 152 ++++++++ 18.21
    2007++++++++ July ++++++++ 01++++++++ 157 ++++++++ 12.27
    2007++++++++ July++++++++ 08 ++++++++ 124 ++++++++ 15.33
    now when you look at the above report layout.....what i want is to display the average time ( diff) for month of june and july.
    so the average time diff of the month of june will be ( total time / record count ). same for july.
    so the result should be for
    JUNE - (32.36 + 11.23 + 18.21) / 3
    JULY - (12.27+15.33) / 2
    also it should convert the decimals (MM) into hours after 60.
    I am getting the sub total for month June as ((32.36 + 11.23 + 18.21) / 3).
    Its not converting the MM in HH even after 60 Min. say for example its showning 40:67. but the correct value should be 41:07
    hope you got my issue.could you please suggest the solution as to how can i get the correct value under the month sub- total.
    thanks,
    pratap.

    Hello venku chittidi ,
    Thanks for the reply.
    But the User wants to display the values in HH:MM instead of MM.
    would it be possible to calcuate HH:MM from HH:HH in the transformation.
    thanks
    pratap.

  • Issue with Bex report - key Figures not populating correctly.

    Hi Experts,
    I am facing an issue with a Bex report. There are three key figures of data type DATE having "Dec - Counter or amount field with comma and sign" datatype. After executing the query, in the report, for some sales documents the key figure fields are coming as 'X' and rest others are coming correctly in the date format as mm\dd\yyyy.
    When i check in the cube, these key figures shows values in decimal format and not in date format. The conversion is happening during execution.
    Pleas show me some light on how to identify the cause of getting 'X' for some Sales documents in the report eventhough some are coming correctly.
    Thanks,
    Anamika
    Edited by: Anamika Soni on Mar 12, 2010 10:48 AM

    Hi,
    The infobject has been defined with datatype "DATE" only. It has also been mapped from datasource to infocube correctly as these key figures are populating correctly for some of the sales documents in the report. It is not like that for all the sales documents the key figures are not converting properly.
    Some Sales documents are not converting into the date fields but for some conversion happens properly in the BEx report. This is the issue.
    Please guide accordingly.
    Many thanks,
    Anamika

  • PO and FI invoice Bex report

    Hi all ,
    I need a BEx report which shows following
    1)     PO with FI Invoice number
    2)     Only PO (without invoice)
    3)     Only Invoice (without PO)
    Well I have PO line item ODS and GL ODS.
    Anyone suggest how should I approach this report??

    Hi Praful,
    Any luck on this question? Or were you able to resolve this? I have the same question.
    If you resolved it, can you pot the answer?
    Thanks,
    Edited by: Paul on Jun 3, 2008 6:09 PM

  • Need suggestion for designing a BEx report

    Hi,
    I need suggestions for designing a BEx report.
    Iu2019ve a DSO with below structure:
    1. Functional Location u2013 Key
    2. Maintenance Plan u2013 Key
    3. Maintenance Item u2013 Key
    4. Call # - Key
    5. Cycle u2013 Data Field
    6. Planned Date u2013 Data Field
    7. Completion Date u2013 Data Field
    This DSO contains data like:
    Functional -
    Plan --- Item -
    Call# --- Cycle -
    Planned Dt -
    Completion Dt
    Location
    11177 -
         134 -
         20 -
         1 -
    T1 -
         02-Jan-2011 -
         10-Jan-2011
    11177 -
         134 -
         20 -
         2 -
    T2 -
         15-Feb-2011 -
    11177 -
         134 -
         20 -
         3 -
    T1 -
         15-Mar-2011 -
    11177 -
         134 -
         20 -
         4 -
    M1 -
         30-Mar-2011 -
    25000 -
         170 -
         145 -
         1 -
    T1 -
         19-Jan-2011 -
         19-Jan-2011
    25000 -
         134 -
         145 -
         2 -
    T2 -
         20-Feb-2011 -
         25-Feb-2011
    25000 -
         134 -
         145 -
         3 -
    T1 -
         14-Mar-2011 -
    Now Iu2019ve to create a report which will be executed at the end of every month and should display the list of Functional Locations whose Cycles were planned in that particular month, along with the last completed Cycle/Date.
    Thus based upon above data, if I execute report at the end of (say) March then report must display:
    Functional ---     Curr. Cycle --- Planned Date --- Prev. completed Cycle --- Prev Completed Date
    Location
    11177 -
         T1 -
         15-Mar-2011 -
    ---     T1 -
    --     10-Jan-2011
    11177 -
         M1 -
         30-Mar-2011 -
    ---     T1 -
    --     10-Jan-2011
    25000 -
         T1 -
         14-Mar-2011 -
    ---     T2 -
    --     25-Feb-2011
    Any idea how can I display Previous Completed Cycle and Completion Date (i.e. the last two columns)?
    Regards,
    Vikrant.

    hi vikrant,
    You can a Cube at the reporting layer  which gets data from DSO and which has these 2 extra characteristics completion date and previous cycle along with other chars and keyfigures from DSO.
    You can populate these  based on your logic in the field routine.
    Hope it helps.
    Regards
    Dev

  • Row and column results to be calculated differently in BEx report

    Hi
    I have a BEx report which consists of profit centre characteristics in the row and headcount key fig in the column over 12 fiscal periods.  This headcount key fig has been set to Calculate Results as 'Last Value'.  This setting is correct because I want the Overall Result of each profit centre along the row to be the heacount value of period 12 or 11 or 10 depending on the period range entered by the user.  Due to this 'Last Value' setting, the Overall Results at the bottom of each fiscal period column also shows the last headcount value ie. the headcount value of the last profit centre displayed on the BEx report.  This is incorrect as the Overall Result should be the summation of headcount for all profit centres for fiscal month.
    What settings should I make to achieve my reporting requirement.  Please let me know. 
    Many thanks,
    Anthony

    Hi Uli
    Changing the 'Calculate result as' to 'counting all values' didn't work.
    What I'm getting from the BEx report is:
                   Headcounts...............................
    Profit Ctr  P1   P2  P3.....P12  Overall Results
    P120         5     6    6        7                7
    P121         6     5    8        9                9
    P122         6     9    8        7                7
    Overall
    Results     6     9     8       7                7
    The last row's Overall Results are incorrect.  It should sum up instead of taking the last profit centre P122 's periodic headcounts.  The last column's Overall Results are correct as they are the P12's headcounts.
    I want the BEx query to look like this:
                   Headcounts...............................
    Profit Ctr  P1   P2  P3.....P12  Overall Results
    P120         5     6    6        7                7
    P121         6     5    8        9                9
    P122         6     9    8        7                7
    Overall
    Results     17   20   22     23              23
    Cheers,
    Anthony

  • Count of rows in ALv report

    Hi!
    I would like to get the count of rows in my ALV report . How to get the count of the rows ? Can anyone guide me in getting it dome please.
    Thanks

    Hi Gaddemmedi!
    I am attaching the report as you had asked for. I have added the things you asked me to do and now I am getting the count on the top of the page. The problem is that though it shows me the count of the lines from the LAV report on top but when I try to filter the records in the report that count first of all dosent change and remain the same as the initial number of record though after filtering records reduce and over that the count lines keep on increasing I mean the count is shown in repeated lines afet lines. Kindly help please.
    Thanks
    *& Report  ZSD_BILLING_HDR_TEXT_sum                                       *
    *&         billing doc. and associated header text report              *
    *&                            CHANGE LOG                               *
    *& jpoon 2007.08.03                  Change request: DEVK905095        *
    *& Move request: SD_1451_01          Requestor: Mona Fox               *
    *& FP14134 - original code.                                            *
    REPORT  zsd_billing_hdr_text_sum MESSAGE-ID zsd NO STANDARD PAGE HEADING.
    * For ALV usage
    TYPE-POOLS: slis.
    DATA: gs_layout   TYPE slis_layout_alv,
          tp_print    TYPE slis_print_alv,
          gt_sort     TYPE slis_t_sortinfo_alv,
          gt_events   TYPE slis_t_event,
          t_fieldcat  TYPE slis_t_fieldcat_alv WITH HEADER LINE,
          repid       TYPE syrepid,               " ABAP Program.
          gt_list_top_of_page TYPE slis_t_listheader,     " Top of page text.
          alv_variant   TYPE disvariant," Customize Disp. Variant
          w_event type slis_alv_event.
    DATA: w_field    TYPE slis_fieldcat_alv.
    TABLES: vbrk, vbrp, vbpa.
    DATA  SLIS_EV_AFTER_OUTPUT.
    data: gs_list_top_of_page type slis_listheader.
    *data: gt_list_top_of_page type slis_t_listheader.
    * Definition of selection screen                                       *
    *   By plant, storage location, sold-to customers, material and        *
    *   posting date of the sales orders                                   *
    SELECTION-SCREEN BEGIN OF BLOCK one WITH FRAME TITLE text-001.
    SELECT-OPTIONS: s_vbeln  FOR  vbrk-vbeln,      " billing doc.
                    s_kunnr  FOR  vbpa-kunnr,      " bill-to customer number.
                    s_werks  FOR  vbrp-werks,      " line item plant.
                    s_fkdat  FOR  vbrk-fkdat,      " billing date.
                    s_fkart  FOR  vbrk-fkart,      " billing type.
                    s_vkorg  FOR  vbrk-vkorg.      " sales org.
    PARAMETERS:     p_hold   AS CHECKBOX.
    SELECTION-SCREEN END OF BLOCK one.
    * ALV display layout
    SELECTION-SCREEN BEGIN OF BLOCK layout WITH FRAME TITLE text-003.
    PARAMETERS: pa_vari TYPE slis_vari DEFAULT ' '. " Display variant.
    SELECTION-SCREEN END OF BLOCK layout.
    * Data Definitions                                                     *
    * Storing Extracted Info.
    TYPES: BEGIN OF t_extract,
             vbeln        TYPE vbeln_vf,   " Sales order number.
             posnr        TYPE posnr,      " line item
             fkart        TYPE fkart,      " billing type.
             vtext        TYPE BEZEI20,    " billing type description.
             fkdat        TYPE fkdat,      " billing date.
             werks        TYPE werks_d,    " line item plant.
             werks_name1  TYPE name1,      " plant description.
             kunnr        TYPE kunnr,      " bill-to customer.
             kunnr_name1  TYPE name1_gp,   " bill-to description.
             netwr        TYPE netwr,      " net value,invoice total $
             zzflag       TYPE boolean,    " hold indicator
             zzreason     TYPE char30,     " header text2 (reason)
             zzuser       TYPE ernam,      " last changed by
             zz_changed_date TYPE dats,    " last changed date
             zz_changed_time TYPE tims,    " last changed time
            END OF t_extract.
    DATA: it_extract  TYPE TABLE OF t_extract WITH HEADER LINE,
          it_extract2 TYPE TABLE OF t_extract WITH HEADER LINE.
    DATA: it_text TYPE TABLE OF tline WITH HEADER LINE.
    DATA: wa_thead type thead.
    DATA: w_tdname type TDOBNAME.
    DATA: L_COUNT TYPE I.
    * initialization
    INITIALIZATION.
      gs_layout-colwidth_optimize = 'X'.
      tp_print-no_print_listinfos = 'X'.
      tp_print-no_coverpage = 'X'.
      PERFORM set_fieldcat.
      PERFORM alv_eventtab_build USING:
    **    Event name     Form to execute     Event internal table
       'TOP_OF_PAGE'  'TOP_OF_PAGE'       gt_events[].
    * Dropdown list for all created ALV layouts, global or user-specific
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR pa_vari.
      PERFORM alv_variant_f4 CHANGING pa_vari.
    * Main BODY of processing logic
    START-OF-SELECTION.
      IF s_vbeln IS INITIAL
      AND s_kunnr IS INITIAL
      AND s_werks IS INITIAL
      AND s_fkdat IS INITIAL
      AND s_fkart IS INITIAL
      AND s_vkorg IS INITIAL.
         MESSAGE i000 WITH text-037 ' ' ' ' ' '.
      ELSE.
        PERFORM extract_data.
      ENDIF.
    END-OF-SELECTION.
      IF it_extract2[] IS INITIAL.
        MESSAGE i000 WITH text-002 ' ' ' ' ' '.
      ELSE.
    * Build headings for report.
    *    PERFORM build_top_of_page  USING gt_list_top_of_page[].
    * describe table it_extract2 lines l_count.
    *write :/ 'TOTAL NO OF ENTRIES', SY-VLINE, 32 L_COUNT.
          PERFORM call_alv.
    *write :/ 'TOTAL NO OF ENTRIES', SY-VLINE, 32 L_COUNT.
      ENDIF.
    *&      Form  EXTRACT_KEY_DATA
    * Retreive the data for the report.
    FORM extract_data.
      CLEAR: it_extract.  REFRESH: it_extract.
    * read and select billing documents
      IF p_hold IS INITIAL.
        SELECT vbrk~vbeln vbrk~fkart vbrk~fkdat vbrk~netwr
               vbrk~zzflag vbrk~zzreason vbrk~zzuser
               vbrk~zz_changed_date vbrk~zz_changed_time
               vbrp~posnr vbrp~werks
          INTO CORRESPONDING FIELDS OF TABLE it_extract
          FROM vbrk INNER JOIN vbrp ON
               vbrk~vbeln = vbrp~vbeln
         WHERE vbrk~vbeln IN s_vbeln
           AND vbrk~fkart IN s_fkart
           AND vbrk~fkdat IN s_fkdat
           AND vbrk~vkorg IN s_vkorg
           AND vbrk~fksto NE 'X'
           AND vbrp~werks IN s_werks.
      ELSE.
    * read 'held' documents only as per selection
        SELECT vbrk~vbeln vbrk~fkart vbrk~fkdat vbrk~netwr
               vbrk~zzflag vbrk~zzreason vbrk~zzuser
               vbrk~zz_changed_date vbrk~zz_changed_time
               vbrp~posnr vbrp~werks
          INTO CORRESPONDING FIELDS OF TABLE it_extract
          FROM vbrk INNER JOIN vbrp ON
               vbrk~vbeln = vbrp~vbeln
         WHERE vbrk~vbeln IN s_vbeln
           AND vbrk~fkart IN s_fkart
           AND vbrk~fkdat IN s_fkdat
           AND vbrk~vkorg IN s_vkorg
           AND vbrk~fksto NE 'X'
           AND vbrk~zzflag = 'X'
           AND vbrp~werks IN s_werks.
      ENDIF.
      IF sy-subrc <> 0.
        MESSAGE i000 WITH text-002 ' ' ' ' ' '.
      ENDIF.
      CHECK sy-subrc = 0.
    * only need first line item for this report.
      SORT it_extract BY vbeln posnr.
      DELETE ADJACENT DUPLICATES FROM it_extract COMPARING vbeln.
      LOOP AT it_extract.
    * Retrieve and select by sales order bill-to on header level
    * as well as lookup bill-to customer name/description
        SELECT SINGLE kunnr FROM vbpa INTO it_extract-kunnr
         WHERE vbeln = it_extract-vbeln
           AND posnr = '000000'
           AND parvw = 'RE'.
        IF it_extract-kunnr IN s_kunnr.
          it_extract-kunnr_name1 = zcl_kna1=>get_name1( it_extract-kunnr ).
        ELSE.
          DELETE it_extract.
          CONTINUE.
        ENDIF.
    * lookup billing type description
        SELECT SINGLE vtext FROM tvfkt
          INTO it_extract-vtext
         WHERE spras = sy-langu
           AND fkart = it_extract-fkart.
        IF sy-subrc <> 0.
          clear it_extract-vtext.
        ENDIF.
    * lookup plant description
        SELECT SINGLE name1 FROM t001w
          INTO it_extract-werks_name1
         WHERE werks = it_extract-werks.
        IF sy-subrc <> 0.
          clear it_extract-werks_name1.
        ENDIF.
        MOVE-CORRESPONDING it_extract TO it_extract2.
        APPEND it_extract2.
       ENDLOOP.
    describe table it_extract2 lines l_count.
    ENDFORM.                    " EXTRACT_DATA
    *&      Form  SET_FIELDCAT
    * Create the field catalogue.
    FORM set_fieldcat .
    *CLEAR W_EVENT.
    *W_EVENT-FORM = SLIS_EV_AFTER_OUTPUT.
    *W_EVENT-NAME = SLIS_EV_AFTER_LINE_OUTPUT.
    *APPEND W_EVENT TO GT_EVENTS.
      CLEAR w_field.
      CLEAR t_fieldcat.  REFRESH t_fieldcat.
      w_field-col_pos = 1.
      w_field-fieldname = 'ZZFLAG'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Hold Printing'(005).
      APPEND w_field TO t_fieldcat.
      w_field-col_pos = 2.
      w_field-fieldname = 'ZZREASON'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Reason'(036).
      APPEND w_field TO t_fieldcat.
      w_field-col_pos = 3 .
      w_field-fieldname = 'VBELN'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Billing Doc'(028).
      w_field-emphasize = 'X'.
      w_field-hotspot   = 'X'.
      APPEND w_field TO t_fieldcat.
      CLEAR w_field.
      w_field-col_pos = 4 .
      w_field-fieldname = 'VTEXT'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Type Description'(030).
      APPEND w_field TO t_fieldcat.
      w_field-col_pos = 5 .
      w_field-fieldname = 'FKDAT'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Billing Date'(031).
      APPEND w_field TO t_fieldcat.
      w_field-col_pos = 6 .
      w_field-fieldname = 'WERKS'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Plant'(012).
      APPEND w_field TO t_fieldcat.
      w_field-col_pos = 7 .
      w_field-fieldname = 'WERKS_NAME1'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Plant Description'(032).
      APPEND w_field TO t_fieldcat.
      w_field-col_pos = 8.
      w_field-fieldname = 'KUNNR'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Bill-to Customer'(033).
      APPEND w_field TO t_fieldcat.
      w_field-col_pos = 9 .
      w_field-fieldname = 'KUNNR_NAME1'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Bill-to Description'(034).
      w_field-emphasize = 'X'.
      w_field-hotspot   = 'X'.
      APPEND w_field TO t_fieldcat.
      CLEAR w_field.
      w_field-col_pos = 10 .
      w_field-fieldname = 'NETWR'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Invoice Amount'(035).
      APPEND w_field TO t_fieldcat.
      w_field-col_pos = 11 .
      w_field-fieldname = 'ZZUSER'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Changed By'.
      APPEND w_field TO t_fieldcat.
      w_field-col_pos = 12 .
      w_field-fieldname = 'ZZ_CHANGED_DATE'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Last Changed Date'(006).
      APPEND w_field TO t_fieldcat.
      w_field-col_pos = 13 .
      w_field-fieldname = 'ZZ_CHANGED_TIME'.
      w_field-tabname = 'IT_EXTRACT2'.
      w_field-seltext_l = 'Last Changed Time'(007).
      APPEND w_field TO t_fieldcat.
    *  W_event-NAME = slis_ev_end_of_list.
    *  W_event-FORM = 'END_OF_LIST'.
    *  APPEND W_event  TO GT_EVENTS.
    *  CLEAR W_event .
    *  w_field-col_pos = 14 .
    *  w_field-fieldname = 'COUNT'.
    *  w_field-tabname = 'IT_EXTRACT2'.
    *  w_field-seltext_l = 'COUNT'.
    *  APPEND w_field TO t_fieldcat.
    ENDFORM.                    " SET_FIELDCAT
    *&      Form  CALL_ALV
    * Call the ALV Grid function.
    FORM call_alv .
      SORT it_extract BY vbeln.
    * repid is necessary since the ALV F.M. does not work properly with
    * sy-repid.
      repid = sy-repid.
      alv_variant-variant  = pa_vari.
      alv_variant-report   = sy-repid.
      alv_variant-username = sy-uname.
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
          i_callback_program      = repid
          i_callback_user_command = 'USER_COMMAND'
          is_layout               = gs_layout
          it_fieldcat             = t_fieldcat[]
          it_sort                 = gt_sort[]
          i_default               = 'X'
          i_save                  = 'A'
          is_variant              = alv_variant
          it_events               = gt_events[]
          is_print                = tp_print
        TABLES
          t_outtab                = it_extract2
        EXCEPTIONS
          program_error           = 1
          OTHERS                  = 2.
    write :/ 'TOTAL NO OF ENTRIES', SY-VLINE, 32 L_COUNT.
      IF sy-subrc NE 0.
        MESSAGE w000 WITH text-004 ' ' ' ' ' '.
      ENDIF.
    ENDFORM.                    " CALL_ALV
    *&      Form  alv_eventtab_build
    *     Pass list of events to be triggered by the ALV function module
    FORM alv_eventtab_build USING  u_name  TYPE slis_alv_event-name
                                   u_form  TYPE slis_alv_event-form
                                   alv_lt_events  TYPE slis_t_event.
      DATA: ls_event TYPE slis_alv_event.   " structure for event handling
      ls_event-name = u_name.
      ls_event-form = u_form.
      APPEND ls_event TO alv_lt_events.
    ENDFORM.                    " alv_eventtab_build
    *       FORM TOP_OF_PAGE                                              *
    FORM top_of_page.
    *gs_list_top_of_page-type = 'H'.
    GS_LIST_TOP_OF_PAGE-INFO = L_COUNT.
    APPEND GS_LIST_TOP_OF_PAGE TO GT_LIST_TOP_OF_PAGE.
      CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
        EXPORTING
          i_logo             = 'NEWALTA_LOGO'
          it_list_commentary = gt_list_top_of_page.
    ENDFORM.                    " TOP_OF_PAGE
    *&      Form  user_command
    * Process the user command.
    *      -->R_UCOMM      User command
    *      -->RS_SELFIELD  Field selected
    FORM user_command USING r_ucomm     LIKE sy-ucomm
                            rs_selfield TYPE slis_selfield.
      DATA: ltp_vbeln TYPE vbeln.  " Sales document number.
      CASE  r_ucomm.
        WHEN '&IC1'.
          IF ( rs_selfield-fieldname = 'VBELN'
            OR rs_selfield-fieldname = 'BILL_VBELN' )
           AND rs_selfield-value IS NOT INITIAL.        " Display sales document.
            ltp_vbeln = rs_selfield-value.
            zcl_sales_doc=>display( ltp_vbeln ).
          ENDIF.
      ENDCASE.
    ENDFORM.                    "user_command
    *&      Form  alv_v-ariant_f4
    * Get the display variant.
    *      <--CTP_VARI  Variant name
    FORM alv_variant_f4 CHANGING ctp_vari TYPE slis_vari.
      alv_variant-report   = sy-repid.             " Report ID
      alv_variant-username = sy-uname.             " User ID
      CALL FUNCTION 'REUSE_ALV_VARIANT_F4'
        EXPORTING
          is_variant = alv_variant
          i_save     = 'A'
        IMPORTING
          es_variant = alv_variant
        EXCEPTIONS
          OTHERS     = 1.
      IF sy-subrc = 0.
        ctp_vari = alv_variant-variant.
      ENDIF.
    ENDFORM.                    " alv_variant_f4

  • Counting Line items in FBL3N

    Hi Gurus,
    If we execute a report FBL3N and system shown 110 items. We use a filter to filter out 15 items so how can we see in a system that how many items are remaining. Is there any facility to count these items?
    Please revert asap.
    Thank You

    Hi
    There is no standard functionality to count the line item. U have to download the data into Excel and do the excercse manually there.
    Thanks
    GG

  • Unable to view report from Bex Report Designer

    Hi,
    When I log on to Bex Report Designer, I click execute button, it is giving a blank page. It is neither giving any error nor any message. We have recently installed NW2004s and BI Cont 703. Now my problem is how to make report visible in the BEX Report Designer.
    Thanks,
    Subhani

    Dear Prakash,
    Thanks for the quick reply. 
    I have religiously followed your Blog.  As far as I know any one who wanna setup BEx has to follow this.  It is the one place where all the settings related to BEx front end were discussed and disclosed.  Thanks a lot for your exemplary attempt.
    Though you have mentioned about the .NET frame work I could not understand how it will effect the "insert" menu of BEx report designer.  But i have checked that also and its matching with your recommendations.
    My question is pretty simple. With sapgui6.40compilation5 with all the latest patches both for gui, BW and BI. Will i get the options of <i>"Report section", "Report section based on Querry"</i>in the <b>"insert"</b> menu of BEx report designer. 
    The mentioned options <i>"Report section", "Report section based on Querry"</i>  were shown in the webnair of BEx report designer.  Pls check the link:
    (As per the SDN these menu items should be available in BEx report designer..Pls observe the Insert menu in the very first few seconds)
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/9c059b57-0701-0010-3283-e5e8669f827e
    We have installed and upgraded the system to spstack 8 and done all the settings.  Our front end is also updated with the service packs.  But we could not get those options.  If you can give me your mail id i can send you the screen shots.
    Thanks & Regards,
    Sridharb

  • Filter in Bex Reports - Very Urgent, Please help!

    Hi,
    I have a report based on CRM transaction which has both header row and item row, the report also has filters like status and product, the status is the header level and product is at the item level, in which case the header row would not have the product details and item row would not have the Status Details. the records would be something like shown below
    Transaction Number       Status         Product
    1111111                        Open
    1111111                                          Product1
    In which case the filter applied on status and product would not return the expected result for ex if filter "Status = Open" is specified then we would just get only the header row and if Filter "Product = Product1" is specified we would just get the detail row, if both the filters are applied we would not get any rows.
    Is there any way to get both the header and item row if filters are specified, how such cases are implemented in Bex reports.
    Thanks
    Akila.R

    Akila,
    please state your query result properly...
    Transaction Number Status Product
    1111111 Open
    1111111 Product1
    would look like
    Transaction Number | Status | Product
    11111111 | Open | #
    11111111 | # | Product 1
    22222222 | Closed | #
    22222222 | # | Product 2
    The issue being that you want say... Open transactions then the the result should be
    Transaction Number | Status | Product
    11111111 | Open | #
    11111111 | # | Product 1
    whereas you are getting
    Transaction Number | Status | Product
    11111111 | Open | #
    and similarly for Product column as well....
    Options :
    1. It could be possible that your model is wrong -
    2. Have the filter include # as well.... include # into the filter by default - ask the users to do the same
    Arun
    Hope it helps...

  • BO migration from BEx reports

    One of my client is running on SAP IS Retail 6.0, and they have few BW reports. Now they are looking for migrating the BEx reports to BO XI.
    They do not want to change anything, but want to port the reports as is to BO from BEx.
    My previous experience of porting BEx reports to BO as is, without puting extra filters of something, to reduce the huge data size images was not good at all.
    Is there any way to have better performance in BO than the current BEx performance, if we want to port the reports as is without any structural change?
    Please share your experience with me.

    My company is running Webi reports using BOBJ XI 3.1 (up to current fixpack level) on SAP BI 7.01 EHP1-SP5. This config gives 50% reduction in Memory, 30% improvement in runtimes, on average compared to 7.0 BI, according to SAP. But is it good enough for full corporate deployment?
    My understanding of the Webi <-> SAP BI architecture is that we still have a large image sent to the XI Box from the query -> universe -> Webi report refresh. The big flaw here in my view is that Webi is disconnected from the OLAP database tables after the refresh, thus must 'image' everything the report requires, in our case into a 32 bit Windows NT box. 
    This is quite different from the SAP BI OLAP front-end model, in which user navigations are threaded in various ways (sometimes from cache, from aggregates, from indexes on the DSO characteristics etc), as we can see in our BI OLAP processing steps in BI statistics.
    After the Webi refresh, there are no 'threads', or calls, back to BI ABAP tables, as the Webi report has to represent all the potential navigation in the MDX model. For this reason it seems a fundamentally resource-intensive architecture, that can induce instability when very large sets of data are retrieved in concurrent user sessions. By "large"  think of the 'cubed' size (count of characteristics X count of key figures X number of transactions).
    If user activity results in concurrent refresh calls to generate large report 'images' from SAP BI, I have observed 100% CPU freeze in BOBJ XI, and user lockout until resources are again freed up, which can take a very long time for certain reports. Subsequently when the large images are subjected to user OLAP navigations, CPU processing again will spike.
    When running large image reports, the Webi performance has been an 'order of magnitude' slower than our reports running on ABAP web. Unfortunately, the risk is greater than just slow performance - there is the CPU and memory resources that are engaged during that extended processing interval as well.
    Much depends on the normal level of user activity. This is a matter of simple statistics. Say your overalll production BI system load averages ten users per hour running reports. If Webi report runtime averages 30 minutes per refresh, and BEx ABAP runs in 5 minutes, the probabillity of concurrent resource collisions is much higher - from 10% to 50%, thus the situation can snowball rapidly.
    I think SAP is working very hard on this problem, but has issued guidance as recently as May 2009,  that if you have current BEx reports that are working, don't migrate them all yet. Unfortunately our users are anxious to run everything in the Webi tool, because it is indeed a super user interface.
    However, customers have until 2016 until the Bex tools are phased out. Interviewed by Searchsap, Jonathan Becher, SAP Sr. VP, said, "There are lots of scenarios that BEx does just fine, if you're confident using BEx, don't rush."  The same article also quoted Cindy Coyle of Coors, who had tested the Webi BOBJ: ""Don't go near Business Objects [until you get a BWA]," Coyle said, "because it'll only add more performance problems on top of what's there today." Article: http://bit.ly/2HJUqf
    Edited by: Douglas Grant on Oct 18, 2009 7:26 PM
    Edited by: Douglas Grant on Oct 19, 2009 9:51 AM

Maybe you are looking for

  • Please help with my incessant spinning wheel of death!

    I have almost always had the spinning circle of death…  Almost the whole life of this late 2011 15" 4 GB mbp.  I just can not easily use this computer anymore. It takes so long to do anything.  I need to exit all apps but the one I am using to make i

  • Created by field determined  in sales order creation

    Hi, I am trying to integrate SAP with a third party program. Sales orders are created by idocs but I want to differentiate the sales orders created by interface from the orders created in SAP directly. So I created a user id as RFCUSER. I want to sho

  • How can I use the "create book" feature without having my album photo sequence altered

    I have created an album with photos that are in a particular order for a reason.  I then process to create a book.  The template then rearranges all my photos.  Is there a way to keep them in the original order I set up? 

  • Steps for java apis and mdm

    Hi all , How we can work with JAVA APIs and MDM . Please tell step by step ways. thanks in advance. Thnks nm

  • What is runMode and runAction in instance.properties?

    Hi, all. Currently, i'm using WAS J2EE 6.40 SP10. In the file /usr/sap/<SID>/<Instance ID>/j2ee/cluster/instance.properties, the following parameters exist. instance.runAction=NONE instance.runMode=NORMAL What are these parameters and what other valu