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

SYNTAX_ERROR

Former Member
0 Likes
1,641

Dear Experts,

would you confirm me about following Syntax Error. Why I am getting this Syntax Error due to missing data on system or due to Program error.

Error in the ABAP Application Program

The current ABAP program "????????????????????????????????????????" had to be

terminated because it has

come across a statement that unfortunately cannot be executed.

The following syntax error occurred in program "Z_PP_SIR_ADDITION " in include

"Z_PP_SIR_ADDITION " in

line 264:

"The data object "ITAB_HEADER" has no component called "LTEXT", but the"

"re are the following components with similar names: "PLTXT", "TEXT1", "

"and "KTEXT"."

" "

The include has been created and last changed by:

Created by: "ABAPDEV "

Last changed by: "ABAPDEV "

Error in the ABAP Application Program

The current ABAP program "????????????????????????????????????????" had to be

terminated because it has

come across a statement that unfortunately cannot be executed.

Regards,

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,537

There looks to be a problem with the program. The program is referring to an internal table field ITAB_HEADER-LTEXT. This does not exist. It is possible, if the table is declared using a structure, that the structure has changed and the field LTEXT has been removed from the structure. Change your program to refer to the correct table field.

10 REPLIES 10
Read only

Former Member
0 Likes
1,538

There looks to be a problem with the program. The program is referring to an internal table field ITAB_HEADER-LTEXT. This does not exist. It is possible, if the table is declared using a structure, that the structure has changed and the field LTEXT has been removed from the structure. Change your program to refer to the correct table field.

Read only

Former Member
0 Likes
1,537

Hi Kashif,

In the Data declaration part,

Begin of ITAB_HEADER,

There is no field LTEXT, Include that field and the error would vanish.

End of ITAB_HEADER.

Read only

former_member209120
Active Contributor
0 Likes
1,537

Hi Anjum,

Simple cause

LTEXT was not in ITAB_HEADER

include LTEXT in  ITAB_HEADER your problem solves 

Example:

Types : begin of  ty_header,

              LTEXT TYPE STRING,          "include like this

              end of ty_header.

Read only

0 Likes
1,537

Dear Ramesh/ raja

would you tell me about the impact of transport request (include smartform) how much time will take this impact to show result on target system. According to My scenario impact of this transport took 15 minutes.

Regards

Read only

sivaganesh_krishnan
Contributor
0 Likes
1,537

Hi Kashif,

As Mentioned Earlier there is no declaration for LTEXT in ITAB_HEADER . So try to declare that field inside ITAB_HEADER. It will solve the issue.

Regards,

Sivaganesh.K

Read only

Former Member
0 Likes
1,537

Hi  ,

Please check your local datatype declaration, you might not have included the field in your declaration you want to use in your prgram.

Ex :

REPORT  ZRWST_SCN.
Tables : sflight.
TYPES : BEGIN OF ty_flight,
        test1 TYPE sflight-carrid,
        test2 TYPE sflight-connid,
        END OF ty_flight.
Data  : it_tab TYPE TABLE OF ty_flight,
            wa_fli TYPE ty_flight.
wa_fli-test3 = 100.

Will give you the  errror.

Include test3 in your declaration of ty_flight as:

TYPES : BEGIN OF ty_flight,

        test1 TYPE sflight-carrid,

        test2 TYPE sflight-connid,

        test3 TYPE sflight-currency,

        END OF ty_flight.

Regards

Read only

Former Member
0 Likes
1,537

Hi Kashif,

The dump has the answer itself. This is because you have used a new variable LTEXT but have not declared it in ITAB_HEADER. Just declare that in the ITAB_HEADER with the data type as that of PLTXT or TEXT1. Please check line no. 264 where you have used LTEXT, SAP does not recognize it.

Regards

Purnand

Read only

former_member220538
Active Participant
0 Likes
1,537

Hi Kashif,

          First read the error message carefully, the reason for the error is mentioned in it.

The problem is that,the Internal table 'ITAB_HEADER'  there is no field called "LTEXT"  , but is there similar fields: "PLTXT", "TEXT1 is there. You have to correct the fieldname in the program or declare a field in the internal table called 'LTEXT'.

Regards

Jeffin

Read only

Former Member
0 Likes
1,537

Hi,

You are getting an error because there is no field named "LTEXT" in ITAB_HEADER.

What you can do is :

  • Check what data is being fetched from the field and see if there is another field that has to be used instead of LTEXT. If found then change LTEXT to that field.
  • OR Add field LTEXT to your internal table if any data has to be stored in it.

regards,

Ashish Rawat

Read only

Former Member
0 Likes
1,537

Hi,

In the Data declaration part you have not declared LTTEXT,

Include LTEXT in the structure.