Skip to Content
-1
Jul 22, 2020 at 11:27 AM

select options

114 Views

Hi, I am just studying ABAP. I'm creating a program that uses select-options and date as input and extracts data by comparing with DB table . I don't know what to do when the get data. So please help me and provide sample code.

REPORT ZEXERCISE.

DATA: WA_DATE TYPE ZDATE-DATBI.

SELECT-OPTIONS DATE FOR WA_DATE NO INTERVALS.

*WA_DATE = ?? (what can i do)

CALL FUNCTION 'CONVERT_DATE_TO_INTERNAL'

EXPORTING

date_external = WA_DATE

IMPORTING

date_internal = WA_DATE.

WRITE :/5 'No',20 'Valid Date'.

SKIP.

tables : ZDATE.

SELECT * FROM ZDATE.

IF ZDATE-DATBI < WA_DATE.

WRITE:/5 ZDATE-NO,20 ZDSTE-DATBI.

ENDIF.

ENDSELECT.