Monday 30 May 2016

Select_____EndSelect

Select.....EndSelect.

  • Select and endselect is acts like loop.
Ex :

Steps :

  1. Go to transaction code SE38.
  2. Enter the program name Z or Y<program name>
  3. Select attribute type as Executable program.
  4. Click on Save.

Source Code

TABLES MAKT.

SELECT-OPTIONS S_MATNR FOR  MAKT-MATNR.


SELECT FROM MAKT INTO MAKT WHERE MATNR IN S_MATNR.

     WRITE / MAKT-MATNR MAKT-SPRAS MAKT-MAKTX.

ENDSELECT.





Input



Output




  • In Select and EndSelect every time control passes to database and write statement .So  Select and EndSelect reduces the performance .




No comments:

Post a Comment