Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

No data showing up

former_member844813
Participant
0 Kudos
816

i need help with my program not showing any data, help me what did i do wrong

here's the code

*&---------------------------------------------------------------------*
*& Report ZGETFBL
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
REPORT ZGETFBL.

TABLES: BSAS,
BSIS.

DATA: ITAB TYPE TABLE OF ZDATAGL,
WA TYPE ZDATAGL.

START-OF-SELECTION.

SELECT MANDT HKONT AUGBL KOSTL DMBTR FROM BSAS
INTO TABLE ITAB
WHERE HKONT = '6105001' AND BUDAT BETWEEN '01.09.2022' AND '30.09.2022'.

SELECT MANDT HKONT AUGBL KOSTL DMBTR FROM BSIS
APPENDING TABLE ITAB
WHERE HKONT = '6105001' AND BUDAT BETWEEN '01.09.2022' AND '30.09.2022'.

END-OF-SELECTION.
MODIFY ZDATAGL FROM TABLE ITAB.

CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
* I_INTERFACE_CHECK = ' '
* I_BYPASSING_BUFFER = ' '
* I_BUFFER_ACTIVE = ' '
* I_CALLBACK_PROGRAM = ' '
* I_CALLBACK_PF_STATUS_SET = ' '
* I_CALLBACK_USER_COMMAND = ' '
* I_CALLBACK_TOP_OF_PAGE = ' '
* I_CALLBACK_HTML_TOP_OF_PAGE = ' '
* I_CALLBACK_HTML_END_OF_LIST = ' '
I_STRUCTURE_NAME = 'ZDATAGL'
* I_BACKGROUND_ID = ' '
* I_GRID_TITLE =
* I_GRID_SETTINGS =
* IS_LAYOUT =
* IT_FIELDCAT =
* IT_EXCLUDING =
* IT_SPECIAL_GROUPS =
* IT_SORT =
* IT_FILTER =
* IS_SEL_HIDE =
* I_DEFAULT = 'X'
* I_SAVE = ' '
* IS_VARIANT =
* IT_EVENTS =
* IT_EVENT_EXIT =
* IS_PRINT =
* IS_REPREP_ID =
* I_SCREEN_START_COLUMN = 0
* I_SCREEN_START_LINE = 0
* I_SCREEN_END_COLUMN = 0
* I_SCREEN_END_LINE = 0
* I_HTML_HEIGHT_TOP = 0
* I_HTML_HEIGHT_END = 0
* IT_ALV_GRAPHICS =
* IT_HYPERLINK =
* IT_ADD_FIELDCAT =
* IT_EXCEPT_QINFO =
* IR_SALV_FULLSCREEN_ADAPTER =
* IMPORTING
* E_EXIT_CAUSED_BY_CALLER =
* ES_EXIT_CAUSED_BY_USER =
TABLES
T_OUTTAB = ITAB
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2
.
IF SY-SUBRC <> 0.
* Implement suitable error handling here
ENDIF.
5 REPLIES 5

FredericGirod
Active Contributor
733

The internal date format of SAP is YYYYMMDD

BETWEEN '22220901' AND '22220931'.

former_member844813
Participant
0 Kudos
733

hi Frederic!

still not showing any data though, can you help me with that

FredericGirod
Active Contributor
733

You have to put a break point (break userid) just before the call of the function and check the internal table is not empty.

If it is empty, check using SE16 transaction if there are some entries with your WHERE conditions

matt
Active Contributor
733

Your biggest mistake is using old technology for your report. Instead of REUSE_ALV_GRID_DISPLAY', use CL_SALV_TABLE. There's many blogs about it.

RaymondGiuseppi
Active Contributor
733
Suggestions
  1. Define the range of date as a select-options and the GL account as a parameter (and then debug and look at the actual values of those fields)
  2. Use an OO ALV class such as CL_SALV_TABLE and not an outdated FM
  3. Update the Z table thru a Function Code managed in the ALV