Skip to Content

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

problem with budat range condition

I am doing some inventory report .

In that i am fetching data from database table mkpf to internal table it_mkpf .my select statement is

SELECT MBLNR BLART BUDAT FROM MKPF

INTO TABLE IT_MKPF

WHERE BUDAT IN R6 .

-


r6 is ranges

the problem is i am getting all records.means it's not checking that budat condition.

can anybody tell me what is the problem in my statement?

Regards

Lalitha.

Tags:
Former Member
Former Member replied

Hi,

Code seems to be ok, but i think you are not appending it.

PARAMETERS:KEYDATE LIKE SY-DATUM.

----------------
DATA:BEGIN OF IT_MKPF OCCURS 0,
MBLNR LIKE MKPF-MBLNR,
BLART LIKE MKPF-BLART,
BUDAT LIKE MKPF-BUDAT,
END OF IT_MKPF.
---------------------
RANGES: R1 FOR SY-DATUM,
R2 FOR SY-DATUM,
R3 FOR SY-DATUM,
R4 FOR SY-DATUM,
R5 FOR SY-DATUM,
R6 FOR SY-DATUM.

--------------------------------
R6-SIGN = 'I'.
R6-OPTION = 'BT'.
R6-LOW = R5-HIGH.
R6-HIGH = KEYDATE.

APPEND R6.

-------------------

Thanks,

Sriram Ponna.

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question