Application Development 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: 

how to do

Former Member
0 Kudos

i am doing remediation in ecc6 and i got Problematic Statements(Error) in SLIN and it is like below,

The LOOP statement processing will be limited

(FROM, TO and WHERE additions in LOOP)

Interaction with group change processing (AT NEW, ...) is undefined

the code is like below

LOOP AT t_itab_main WHERE prgtype = c_pgmtp_mr.

  • ON CHANGE OF t_itab_main-requestor_name. uvp

AT NEW requestor_name.

IF g_flag NE 0.

NEW-PAGE.

ENDIF.

ENDAT.

  • ENDON.

WRITE: /2 t_itab_main-prgnumb, "Program #

14 t_itab_main-descript, "Description

t_itab_main-effstart, "Effective Begin Date

68 t_itab_main-effend, "Effective End Date

81 t_itab_main-requestor_name(20), "Requestor Name

102 t_itab_main-sales_area, "Sales Area " Smb002

115 t_itab_main-solddesc. "Sold To/Broker "smb002

g_flag = 1.

ENDLOOP.

please tell me how to remove this error

3 REPLIES 3

Former Member
0 Kudos

Hi,

Problem is you are using AT NEW statement in conditional loop.

AT NEW statement is never used in conditional loop.It is clearly written SAP help.

What you can do is filter your table into new internal table having only entries satisfying your where condition in loop.

and loop this new internal table.

Edited by: Anurag_n on Apr 9, 2010 11:48 AM

Former Member
0 Kudos

Hi,

When you use this AT NEW statement with particular field then it compares the entire record from that field . So it is just like gambling some times you may get corect output and sometimes you may not. So that;s way in SLIN it will say it as Problamatic statement, try to remove the control break statement and do it using other logic.

Thanks,

Srinivas Dummu

Former Member
0 Kudos

Could be better if you use a meaningful subject lines in all your posts.