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

short dump with the select statement

Former Member
0 Likes
1,538

Hi All,

In a program i'm writing the select statement like this.

And it is giving a short dump saying the following message:

The code is:

DATA: BEGIN OF T_VBAP OCCURS 0,

VBELN LIKE VBAP-VBELN,

POSNR LIKE VBAP-POSNR,

END OF T_VBAP.

SELECT VBELN

POSNR

UP TO 30 ROWS

INTO CORRESPONDING FIELDS OF TABLE T_VBAP

FROM VBAP.

The Short Dump:

Error Analysis:

With the statement

"SELECT ... INTO TABLE itab"

internal tables with a deep line type are not supported at the argument

position "itab".

Internal tables with a deep line type are internal tables

with lines that are themselves either internal tables or

structurese that contain internal tables directly or indirectly as

components.

In this case, the internal table "itab" has the non-flat

line type "v".

Can you please let me know how to solve this.

Thanks a lot,

Message was edited by: dev a

Hi,

You u can find <b>Information where occured</b> in shortdump.Will u please send that information if possible.

Thanks & Regards,

Sunil.K

11 REPLIES 11
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
1,438

Well, the only thing that I can see is that the T_VBAP is not defined correctly. This may be a typo in this post. I would think that you would get a syntax error on this.



DATA: BEGIN OF T_VBAP OCCURS 0,
VBELN LIKE VBAP-VBELN,
POSNR LIKE VBAP-POSNR,
END OF <b>IT_VBAP.</b>   " This should be T_VBAP

SELECT VBELN
POSNR
UP TO 30 ROWS
INTO CORRESPONDING FIELDS OF TABLE T_VBAP
FROM VBAP.


REgards,

Rich Heilman

Read only

0 Likes
1,438

Rich,

sorry that is a type mistake. The program is not giving any syntax errors at all.

but when I execute the program it is short dumping.

thnx

Read only

Former Member
0 Likes
1,438

Dev,

Try doing this.

TYPES: BEGIN OF TY_VBAP ,

VBELN TYPE vBELN,

POSNR TYPE POSNR,

END OF TY_VBAP.

DATA : TVBAP type table of TY_VBAP.

SELECT VBELN POSNR UP TO 30 ROWS

INTO CORRESPONDING FIELDS OF TABLE T_VBAP FROM VBAP.

Regards,

Ravi

Note : Please mark all the helpful answers

Read only

0 Likes
1,438

I'm actually not getting a dump. Your code works pretty good in my system. Are you sure that it is dumping at this select and not another. If you can, please post all of the code of the program.

Regards,

Rich Heilman

Read only

0 Likes
1,438

In the dump, it will also show the code that caused the dump. Would you please post that portion of the dump?

Rob

Read only

0 Likes
1,438

Are you sure you're not doing something like:


REPORT ztemp LINE-SIZE 80 MESSAGE-ID zc.

TABLES: vbap.

DATA: BEGIN OF t_vbap OCCURS 0,
vbeln LIKE vbap-vbeln,
posnr LIKE vbap-posnr,
END OF t_vbap.

DATA: BEGIN OF otab OCCURS 0,
        field LIKE table of t_vbap,
      END   OF otab.

SELECT vbeln
posnr
UP TO 30 ROWS
INTO CORRESPONDING FIELDS OF TABLE otab
FROM vbap.

I get exactly the same dump you do when I run this.

Rob

Read only

0 Likes
1,438

hi dev,

TABLES: vbap.

DATA: BEGIN OF t_vbap,

vbeln LIKE vbap-vbeln,

posnr LIKE vbap-posnr,

END OF t_vbap.

Data: <b>it_vbap like t_vbap with header line.</b>

SELECT vbeln

posnr

UP TO 30 ROWS

INTO CORRESPONDING FIELDS OF TABLE

<b>it_vbap</b> FROM vbap.

Check it in this way ... it is not giving me any dump and is fetching me 30 rows of records...

Regards,

Santosh

Read only

Former Member
0 Likes
1,438

Hi,

You u can find <b>Information where occured</b> in shortdump.Will u please send that information if possible.

Thanks & Regards,

Sunil.K

Read only

Former Member
0 Likes
1,438

Hi Dev,

Try the following code:-

TYPES: BEGIN OF T_VBAP,

VBELN LIKE VBAP-VBELN,

POSNR LIKE VBAP-POSNR,

END OF T_VBAP.

DATA: LIT_VBAP TYPE TABLE OF T_VBAP.

SELECT VBELN POSNR

UP TO 30 ROWS

INTO TABLE LIT_VBAP

FROM VBAP.

I have checked it. It is not giving a short dump and it is returning 30 records

Read only

Former Member
0 Likes
1,438

This code is ok, and I agree with others here that the error is coming from somewhere else. Since it is talking about SELECT INTO TABLE, why don't you check all your SELECT statements and see if there is any INTO TABLE used in those SELECTs and if the internal table used has deep structure.

Please post all your select statements. Also, the dump should have told you exactly where the error occured.

Srinivas

Read only

nishanthbhandar
Contributor
0 Likes
1,438

Dev,

From the little information that is available from your side one can figure out that the dump is caused by incorrect destination for retrieval of records from whichever table you are trying to select.Your dump analysis reads :

<b>internal tables with a deep line type are not supported at the argument</b> -


this means that you have declared a type or a internal table which is having a deep stucture.Naturally the line type of the table from which you are trying to fetch data is not matching with the <b>ITAB</b>.

Look into the dump analysis.You can use transaction ST22 for this.If you have already corrected your problem then please make sure that you reward deserving guys.As you can see lot of people have already supplied their suggestions.Please dont forget to close the thread once your problem is solved.