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: 
Read only

regarding this select statement

Former Member
0 Likes
391

hi,

please explain this code clearly.

perform rajesh.

from rajesh.

select xxxx xxxx xxxx from table XXXX where XXXX = XXXX

exit.

endselect.

endform.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
366

Hi,

select xxxx xxxx xxxx from table XXXX where XXXX = XXXX

exit.

endselect.

In the Where clause, if XXXX = XXXX (If these both fields are same) then the select will be exited.

Regards

Sudheer

2 REPLIES 2
Read only

Former Member
0 Likes
367

Hi,

select xxxx xxxx xxxx from table XXXX where XXXX = XXXX

exit.

endselect.

In the Where clause, if XXXX = XXXX (If these both fields are same) then the select will be exited.

Regards

Sudheer

Read only

Former Member
0 Likes
366

HI,

<b>*-- This Statement is going to call the Subroutine called rajesh</b>

perform rajesh.

*-- This Form.. endForm is the Subroutine definition

from rajesh.

<b>*-- Select the fields xxxx can be any fiedls from the table XXXX

where the field XXXX is equal the value in the field XXXX.

if it finds one such entry in the table then come out of the select statment no more loop into the select.

select ... endselect will select one record at a time and loops. .. here you are using exit so when this select finds one record then it will come out of the loop.</b>

select xxxx xxxx xxxx from table XXXX where XXXX = XXXX

exit.

endselect.

endform.

Example :

tables : vbap.

<b>*-- if the select finds an entry in vbap for sales order number 123456 then it will come out</b>

select vbeln posrn from vbap where vbeln = '123456'.

exit.

endselect.

Thanks

Mahesh