Skip to Content
Former Member
Sep 02, 2014 at 02:15 PM

DUMP Fetch Next Cursor Instruction after upgrade SAP BASIS to 740


Hello experts,

I really need your help.

I have a program that uses the following abap code. After upgrade to SAP Basis 740 this instructions is always performing dumps DBSQL_ILLEGAL_SWITCH and there is no way I can find what pattern it is (it does not have the same behavior with the same selection screen variables):

open cursor gv_cursr for

select tknum tpnum vbeln from vttp

for all entries in gt_outpt

where vbeln eq gt_outpt-remessa.


*** Ini Vanda Roxo 01.09.2014 - Validação do sy-subrc após uprade.

* if sy-subrc eq 0.

fetch next cursor gv_cursr

into table gt_delss package size 50000.

if sy-subrc eq 0.

sort gt_delss by vbeln.

delete adjacent duplicates from gt_delss comparing vbeln.

append lines of gt_delss to gt_vttps.




* endif.


close cursor gv_cursr.

free gt_delss.

sort gt_vttps by vbeln.

I did not write this code, but I think the goal was to read VTTP data without a key fields, so they used this instruction because the volume of records returned was huge.

Can you please help?

Don't know what to do at this point.

Thank you!


Best regards,

Raquel Oliveira