cancel
Showing results for 
Search instead for 
Did you mean: 

Low performance of FBL3N report

satendra_sapco
Explorer
0 Kudos

Hi Team,

I have activate BTE 1650 also after that FBL3N report is running very slow.

please suggest me how can I improve performance of this report

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

You can experiment with enabling and disabling the BTE in FIBF to determine the perfomance impact.

Furthermore the new approach to do this is with a BADI (i'm not sure if the performance is affected) 1323512 - Line items: BADI FI_ITEMS_CH_DATA / 1504612 - Line item: Offsetting account information (BAdI FI_ITEMS_CH_DATA)

Last but not least: you'll need an ABAP or BASIS consultant to solve this

iklovski
Active Contributor
0 Kudos

Of course, you would have performance problems: you run a selection on BSEG!

abhay_kesarkar
Explorer
0 Kudos

Hi Mr Eli Klovaski,

we required selection from bseg without we cannot get Purchase order no and vendor code so how can we improve performance of FBL3N report

iklovski
Active Contributor
0 Kudos

Read some other table, which is indexed; i.e. BSIK/BSAK.

You cannot expect good performance while reading BSEG.

abhay_kesarkar
Explorer
0 Kudos

Hi Mr Eli Klovaski,

Thanks for reply

All the data is not available in BSIK and BSAK table i.e Purchase order No. This information is must required so that we used BSEG Table please suggest any other table can we use instead of BSIK,BSAK

Lakshmipathi
Active Contributor
0 Kudos

Have a look at the following OSS notes

  1. 977792 - FBL3N: Performance improvement while reading archive records
  2. 904163 - FBL3N - performance problem after Support Package 10
  3. 2568807 - Performance improvement for FBL3N
iklovski
Active Contributor
0 Kudos

Hi,

a) Was performance reasonable without BTE?

b) Are you accessing archived records in your selection when you run FBL3N?

c) What is your SAP release?

If the answer to a) is positive, then post screenshot of what you have put in BTE. Verify that the algorithm is not running on non-indexed fields.

Regards,

Eli

Former Member
0 Kudos

Please suggest me how to check "algorithm is not running on non-indexed fields"

iklovski
Active Contributor
0 Kudos

What is your code in BTE? If you just, judging by the fields you added in the structure, bringing the texts to the report, it shouldn't impact much the performance unless the code is made in peculiar way.

satendra_sapco
Explorer
0 Kudos
FUNCTION Z_INTERFACE_00001650.
*"----------------------------------------------------------------------
*"*"Local Interface:
*"  IMPORTING
*"     VALUE(I_POSTAB) LIKE  RFPOS STRUCTURE  RFPOS
*"  EXPORTING
*"     VALUE(E_POSTAB) LIKE  RFPOS STRUCTURE  RFPOS
*"----------------------------------------------------------------------

*-------------- Initialize Output by using the following line ----------
  E_POSTAB = I_POSTAB.

  TABLES : BSEG, LFA1,KNA1.
  DATA: W_NAME1 TYPE LFA1-NAME1,
        W_NAMEC TYPE KNA1-NAME1,
  W_LIFNR TYPE LFA1-LIFNR,
  W_KUNNR TYPE BSEG-KUNNR,
  W_HKONT TYPE BSEG-HKONT,
  W_TXT TYPE SKAT-TXT20,
  W_EBELN TYPE EKKO-EBELN.
  IF E_POSTAB-BLART EQ 'WE'.
*  “For MIGO documents
    SELECT SINGLE EBELN INTO W_EBELN FROM BSEG WHERE BELNR = E_POSTAB-BELNR
    AND BUKRS = E_POSTAB-BUKRS
    AND GJAHR = E_POSTAB-GJAHR
    AND HKONT = E_POSTAB-HKONT.

*** for GL accunt and description for expenses
    SELECT SINGLE HKONT FROM BSEG INTO E_POSTAB-ZHKONT WHERE BELNR = E_POSTAB-BELNR AND BSCHL in ('81','91')
     AND    KOART ='S'.
    SELECT SINGLE TXT20 FROM SKAT INTO E_POSTAB-ZTXT20 WHERE SAKNR = E_POSTAB-ZHKONT.

    IF SY-SUBRC = 0.

      SELECT SINGLE LFA1~NAME1
      LFA1~LIFNR
      INTO (W_NAME1, W_LIFNR)
      FROM EKKO INNER JOIN LFA1 ON EKKO~LIFNR =
      LFA1~LIFNR WHERE EKKO~EBELN = W_EBELN.

      IF SY-SUBRC = 0.

        E_POSTAB-ZNAME = W_NAME1.
        E_POSTAB-ZLIFNR = W_LIFNR.

        CLEAR:W_NAME1,W_LIFNR.
      ENDIF.
    ENDIF.
  ELSE.
*  “For other than MIGO doc
*i.e. Vendor Invoice
    SELECT SINGLE LIFNR
    FROM BSEG
    INTO (E_POSTAB-ZLIFNR)
    WHERE BUKRS = I_POSTAB-BUKRS
    AND GJAHR = I_POSTAB-GJAHR
    AND BELNR = I_POSTAB-BELNR
    AND BSCHL IN ('31','21')
    AND KOART = 'K'.
***  Customer code

    SELECT SINGLE KUNNR
  FROM BSEG
  INTO (E_POSTAB-ZKUNNR)
  WHERE BUKRS = I_POSTAB-BUKRS
  AND GJAHR = I_POSTAB-GJAHR
  AND BELNR = I_POSTAB-BELNR
  AND BSCHL IN ('01','02','11','12','15')
  AND KOART = 'D'.
**    Fetching Customer name
    SELECT SINGLE NAME1
FROM KNA1
INTO E_POSTAB-ZNAMEC
WHERE KUNNR = E_POSTAB-ZKUNNR.
* Fetching Vendor Name
    SELECT SINGLE NAME1
    FROM LFA1
    INTO E_POSTAB-ZNAME
    WHERE LIFNR = E_POSTAB-ZLIFNR.
  ENDIF.

ENDFUNCTION.