Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

regarding nested looping

hi experts

i am having let us take 50 input fields which are given by the end user and and with the given fields i have to find the best possible combination.

LOOP AT T_TAB1 INTO W_TAB1.

LOOP AT T_TAB2 INTO W_TAB2.

LOOP AT T_TAB3 INTO W_TAB3.

W_TEMP-K = W_TAB1-A.

W_TEMP-L = W_TAB2-B.

W_TEMP-M = W_TAB3-C.

TEMP4 = W_TEMP-K + W_TEMP-L + W_TEMP-M .

IF TEMP4 <= P_CMP.

temp5 = p_cmp - temp4.

WRITE :/ W_TEMP-K , '' , W_TEMP-L , '' , W_TEMP-M , '<=' , P_CMP , temp5 .

ENDIF.

ENDLOOP.

ENDLOOP.

ENDLOOP.

now my question is if one of the input field is not given then i want to continue the process without the value which is not given in the input .is there any way in which the loop can be jumped if there no input for that field and continue with that process.

Tags:
Former Member
Not what you were looking for? View more on this topic or Ask a question