*---------------------------------------------------------------------* * FORM SELECT * *---------------------------------------------------------------------* * ........ * *---------------------------------------------------------------------* * --> PARAM * * <-- SY-SUBRC * *---------------------------------------------------------------------* FORM select USING param. FIELD-SYMBOLS: TYPE ANY. sy-subrc = 8. IF param EQ space AND status-action NE transportieren. "normal selection (not deleted entries) PERFORM normal_select. ELSE. CASE param. WHEN geloescht. CHECK EQ geloescht OR EQ neuer_geloescht OR EQ update_geloescht. CLEAR sy-subrc. IF x_header-selection NE space. IF x_header-bastab <> space AND x_header-texttbexst <> space. ASSIGN TO . ELSE. ASSIGN TO . ENDIF. CALL FUNCTION 'TABLE_RANGE_CHECK' EXPORTING tabname = x_header-maintview entry = total entry_text = ddic = 'N' key = 'N' ignore_blank_subsetfields = 'N' TABLES x_namtab = x_namtab x_header = x_header sellist = dpl_sellist EXCEPTIONS entry_not_fits = 1 no_value_for_subset_ident = 2. IF sy-subrc EQ 2. RAISE no_value_for_subset_ident. ENDIF. ENDIF. WHEN markiert. IF status-delete EQ geloescht. CHECK EQ geloescht OR EQ neuer_geloescht OR EQ update_geloescht. ENDIF. CHECK EQ param. CLEAR sy-subrc. IF x_header-selection NE space. IF x_header-bastab <> space AND x_header-texttbexst <> space. ASSIGN TO . ELSE. ASSIGN TO . ENDIF. CALL FUNCTION 'TABLE_RANGE_CHECK' EXPORTING tabname = x_header-maintview entry = total entry_text = ddic = 'N' key = 'N' ignore_blank_subsetfields = 'N' TABLES x_namtab = x_namtab x_header = x_header sellist = dpl_sellist EXCEPTIONS entry_not_fits = 1 no_value_for_subset_ident = 2. IF sy-subrc EQ 2. RAISE no_value_for_subset_ident. ENDIF. ENDIF. WHEN bcset_only. "HCG Display only data from BC-Set READ TABLE vim_bc_entry_list INTO vim_bc_entry_list_wa WITH TABLE KEY viewname = x_header-viewname keys = . IF sy-subrc NE 0. sy-subrc = 8. ENDIF. CHECK sy-subrc EQ 0. IF x_header-selection NE space. IF x_header-bastab <> space AND x_header-texttbexst <> space. ASSIGN TO . ELSE. ASSIGN TO . ENDIF. CALL FUNCTION 'TABLE_RANGE_CHECK' EXPORTING tabname = x_header-maintview entry = total entry_text = ddic = 'N' key = 'N' ignore_blank_subsetfields = 'N' TABLES x_namtab = x_namtab x_header = x_header sellist = dpl_sellist EXCEPTIONS entry_not_fits = 1 no_value_for_subset_ident = 2. IF sy-subrc EQ 2. RAISE no_value_for_subset_ident. ENDIF. ENDIF. WHEN by_field_contents. PERFORM normal_select. CHECK sy-subrc EQ 0. IF x_header-bastab NE space AND x_header-texttbexst NE space. * table with texttable CALL FUNCTION 'QUERY_CHECK' EXPORTING record = textrecord = EXCEPTIONS no_hits_in_record = 4 parameter_error = 8. ELSE. * view or single table CALL FUNCTION 'QUERY_CHECK' EXPORTING record = * record = total EXCEPTIONS no_hits_in_record = 4 parameter_error = 8. ENDIF. WHEN OTHERS. "neuer_eintrag or aendern IF x_header-bastab NE space AND x_header-texttbexst NE space AND param EQ aendern. CHECK EQ param OR EQ param OR NE neuer_eintrag AND EQ neuer_eintrag. ELSE. CHECK EQ param. ENDIF. CLEAR sy-subrc. IF x_header-selection NE space. IF x_header-bastab <> space AND x_header-texttbexst <> space. ASSIGN TO . ELSE. ASSIGN TO . ENDIF. CALL FUNCTION 'TABLE_RANGE_CHECK' EXPORTING tabname = x_header-maintview entry = total entry_text = ddic = 'N' key = 'N' ignore_blank_subsetfields = 'N' TABLES x_namtab = x_namtab x_header = x_header sellist = dpl_sellist EXCEPTIONS entry_not_fits = 1 no_value_for_subset_ident = 2. IF sy-subrc EQ 2. RAISE no_value_for_subset_ident. ENDIF. ENDIF. ENDCASE. ENDIF."param eq space and status-action ne transportieren ENDFORM. "select