2007 Apr 25 5:12 AM
hi all..
i am getting an error like this while executing. This modify is bng called inside a loop.
"You attempted to change, delete or create a line in the internal table itab[] but no valid cursor exists. "
MODIFY itab FROM wa_itab TRANSPORTING delete
where delete is a flag.
hi
MODIFY itab FROM wa_itab TRANSPORTING delete
either specify index sy-tabix additon or use keyword table.
like
MODIFY itab FROM wa_itab TRANSPORTING delete index sy-tabix
or
MODIFY TABLE itab FROM wa_itab TRANSPORTING delete.
Regards,
Naveen Natarajan
2007 Apr 25 5:15 AM
Hi,
Can you please provide the data whcih you are modifying..
The syntax is correct.
I can suggest you one thing..
You use field-symbols for this type of coding, there will be no chance of useing the Modify statement when using field symbols..
regards,
nazeer
Message was edited by:
nazeer shaik
2007 Apr 25 5:16 AM
hi
u need to have a cursor position for such a modify satatement . there mite be somethn wrong wth ur loop statement.
and one more thing what ru achieving by transpoting delete is the flag really required .
Do revert back
regards
navjot
reward if helpfull
2007 Apr 25 5:23 AM
2007 Apr 25 7:33 AM
Hi,
Chek your internal table data and work area data in debugging. It will help you and you can solve that problem.
Reply for queries, shall post the updates.
Regards.
Kumar
2007 Apr 25 7:37 AM
Hi,
Try with below syntax
MODIFY TABLE itab [FROM wa]
[TRANSPORTING f1 ... fn].
Put the "TABLE" key word before internal table....
Don't forget to reward if useful
2007 Apr 25 10:18 AM
hi
MODIFY itab FROM wa_itab TRANSPORTING delete
either specify index sy-tabix additon or use keyword table.
like
MODIFY itab FROM wa_itab TRANSPORTING delete index sy-tabix
or
MODIFY TABLE itab FROM wa_itab TRANSPORTING delete.
Regards,
Naveen Natarajan
2007 Apr 25 10:21 AM
You need to have the index addition to avoid this
MODIFY scarr_tab INDEX idx FROM scarr_wa .
or
MODIFY TABLE scarr_tab FROM scarr_wa
TRANSPORTING currcode.
courtesy SAP Help
santhosh
2007 Apr 25 10:25 AM
Hi,
Try using where condition.
modify itab FROM wa_itab TRANSPORTING delete where condition.
2007 Apr 25 10:28 AM
Hi Cynthia,
for the statement that you have written...
MODIFY itab FROM wa_itab TRANSPORTING delete.
this statement needs to be in the loop...LOOP at itab...ENDLOOP.
and it must not be in this case...
so you need to pass another addition INDEX to this statement..
MODIFY itab FROM wa_itab TRANSPORTING delete INDEX id...
here id is the line id of the itab that you need to modify.
This will solve your problem,
<b>Reward points for helpful answers,</b>
Regards,
Tejas
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |