Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

PERFORMANCE OF INNER JIONS ..

HI,

SELECT LIFNR MBLNR MATNR WERKS SUM( MENGE ) SUM( DMBTR )

CHARG BWART MJAHR INTO

(ITAB-LIFNR, ITAB-MBLNR, ITAB-MATNR, ITAB-WERKS,

ITAB-MENGE,ITAB-DMBTR, ITAB-CHARG, ITAB-BWART,

ITAB-MJAHR)

FROM MSEG

WHERE ( WERKS IN WERKS AND

LIFNR IN LIFNR AND

CHARG IN CHARG AND

BWART BETWEEN '101' AND '102' AND

EBELN BETWEEN '4701000000' AND '4701999999' ) OR

( WERKS IN WERKS AND

LIFNR IN LIFNR AND

CHARG IN CHARG AND

BWART BETWEEN '101' AND '102' AND

EBELN BETWEEN '4704000000' AND '4704999999' )

GROUP BY LIFNR MBLNR MATNR WERKS CHARG BWART MJAHR.

SELECT BUDAT INTO (ITAB-BUDAT)

FROM MKPF

WHERE BUDAT IN BUDAT

AND MBLNR EQ ITAB-MBLNR

AND MJAHR EQ ITAB-MJAHR.

SELECT SINGLE BKLAS INTO (TEMP_BKLAS)

FROM MBEW WHERE BKLAS IN BKLAS AND

MATNR EQ ITAB-MATNR.

I HAVE TO COMBINE ALL THE ABOVE PROGRAMS IN 1 STMTS.

INSTEAD OF GROUP BY WAT TO USE TO REDUCE PERFORMANCE ISSUE

CAN ANY ONE HELIP ME OUT?

Former Member
Not what you were looking for? View more on this topic or Ask a question