ABAP/4
Select...Where & Select...Check in ABAP/4
Select...Where
SELECT * FORM SPFLI
WHERE CARRID = ’LH’.
...
...
...
ENDSELECT.
Select...Check
In above logic, Select...Where is better than Select...Check because the database can then user an index and system resource load is considerably less.SELECT * FORM SPFLI.
CHECK SPFLI-CARRID = ’LH’.
...
...
...
ENDSELECT.
- thitima's blog
- Add new comment
- 1049 reads
SELECT...INTO TABLE & SELECT...APPEND in ABAP/4
Select...Into Table
DATA: itab LIKE SPFLI OCCURS 0 WITH HEADER LINE.
SELECT * FORM SPFLI INTO TABLE itab.
Select...Append
In above logic, Select...Into Table is faster than Select...Append.DATA: itab LIKE SPFLI OCCURS 0 WITH HEADER LINE.
SELECT * FORM SPFLI INTO itab.
APPEND itab.
ENDSELECT.
- thitima's blog
- Add new comment
- 4839 reads
How to call SMARTFORMS from ABAP/4
When you create the form by SMARTFORMS, system will automatically create the function module for called by ABAP/4. You can get this function module by apply function module "SSF_FUNCTION_MODULE_NAME" and send the form name. This function will return the function name for call SMARTFORMS that you created.
Example
DATA: smf_name TYPE TDSFNAME VALUE ’ZSMARTFORM01’,
fn_name TYPE RS38L_FNAM.
CALL FUNCTION ’SSF_FUNCTION_MODULE_NAME’
EXPORTING
FORMNAME = smf_name
IMPORTING
FM_NAME = fn_name.
- thitima's blog
- 2 comments
- Read more
- 4547 reads
How to Popup Confirm Message in ABAP/4
When you want to popup message to confirm action, you can apply function module "POPUP_TO_CONFIRM_WITH_MESSAGE". The function will return:
- ’A’ - Yes
- Others - No or Cancel
Example
CALL FUNCTION ’POPUP_TO_CONFIRM_WITH_MESSAGE’
EXPORTING
DIAGNOSETTEXT1 = ’Do you want save data?’
TEXTLINE1 = ’ ’
TITEL = ’Confirm message!’
IMPORTING
ANSWER = lv_answer.
- thitima's blog
- Add new comment
- Read more
- 6646 reads
Formatting Selection Screens in ABAP/4: Blank Lines, Underlines and Comments
- Blank Lines
Example
SELECTION-SCREEN SKIP 3.
- Underlines
Example
SELECTION-SCREEN ULINE.
SELECTION-SCREEN ULINE /1(20).
- Comments
Example
- thitima's blog
- Add new comment
- Read more
- 932 reads
Loop...Where & Loop...Check in ABAP/4
Loop...Where
LOOP AT itab where key = pa1.
...
...
...
ENDLOOP.
Loop...Check
In above logic, Loop...Where is better than Loop...Check because Loop...Where verifys the specified condition internally.LOOP AT itab.
CHECK itab-key = pa1.
...
...
...
ENDLOOP.
- thitima's blog
- Add new comment
- 4923 reads
Recent comments
3 years 4 weeks ago
3 years 9 weeks ago
3 years 9 weeks ago
3 years 10 weeks ago
3 years 10 weeks ago
3 years 12 weeks ago
3 years 12 weeks ago
3 years 12 weeks ago
3 years 13 weeks ago
3 years 13 weeks ago