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

Error in select query with package size

Former Member
0 Likes
1,145

Hi Experts,

I have an issue.

SELECT * FROM (w_tab-tablename) I

NTO CORRESPONDING FIELDS OF TABLE <lt_data> PACKAGE SIZE 10000.

Am splitting the table for every 10000 records,for first time the select query is successful.

But when it comes for the second 10000 records,its throwing the following dump.

"DBIF_RSQL_INVALID_CURSOR"

Help Appreciated

Hi Experts,

I have an issue.

SELECT * FROM (w_tab-tablename) I

NTO CORRESPONDING FIELDS OF TABLE <lt_data> PACKAGE SIZE 10000.

Am splitting the table for every 10000 records,for first time the select query is successful.

But when it comes for the second 10000 records,its throwing the following dump.

"DBIF_RSQL_INVALID_CURSOR"

Help Appreciated

3 REPLIES 3
Read only

Former Member
0 Likes
855

Hi,

I am suggesting you that please omit corresponding fields and

and one thing you need to remember.

selecting fields using select * statement .. data values internally will be in sequential order.

for example .

field 1, field 2,, ... fn like that.

so the table which you are using to store values should have same sequence of fields.

otherwise it may be goes to dump which out showing any error messages.

Regards,

Prasad

Read only

Former Member
0 Likes
855

Hi vadnalav,

I understand this error is coming while you are debugging.

This error will not come if you do not debug. While debugging, it will come in the 2nd loop error.

This is by design. Debugging causes a commit work, and hence closes the current cursor. So just put your break-point after the full loop, if u want to debug. Do not debug in between the loop.

For reference, see this

[|]

regards,

amit m.

Read only

Former Member
0 Likes
855

Hi,

There are a few instances where you get this error.

1) If you are debugging inside select ... endselect.

2) You have written any of the below statements inside select ... endselect.

Please look at the dump .. you'll find the below ..

MESSAGE (apart from MESSAGE S...)

COMMIT WORK

ROLLBACK WORK

BREAK-POINT

WAIT

CALL FUNCTION ... DESTINATION (synchronous RFC)

CALL FUNCTION ... STARTING NEW TASK

RECEIVE RESULTS

CALL DIALOG

CALL SELECTION-SCREEN

CALL TRANSACTION

CALL SCREEN, or any other statement that results in the display of a

new screen

Regards,

Srini.