Application Development 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: 

Strange problem in ABAP

Former Member
0 Kudos

Hello All,

We are facing a strange problem in simple abap program.

Following is the program .

PROGRAM DEMO_ELEMENTARY_DATA_OBJECTS.

DATA NCK1(40) type c .

NCK1 = ‘THE’.

WRITE NCK1.

When we try to check the program system throws error message stating

"Program ZNTEST Field "‘THE’" is unknown. It is neither in one of the specified tables nor defined by a "DATA" statement."

Please let us know the cause of the problem.

Thank you.

Regards

Nimesh

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Nimesh,

Please copy your code into a notpad file and check it. The single quote used in 'the' will look diffrent. Change it in the note pad and copy the code into your ABAP editor. This will sovle your problem. We are also facing the same problem from few days.

Thanks and Regards,

Bharat Kumar Reddy.V

Message was edited by: Bharat Kumar Reddy Vaka

8 REPLIES 8

Former Member
0 Kudos

Hi Nimesh,

I think there is some special character coming for some reason. Delete the line NCK1 = 'THE' and re-write the same code and then try to activate.

I've done it on my system and its working.

regards,

Satyadev Dutta

Former Member
0 Kudos

Hi Nimesh,

Please copy your code into a notpad file and check it. The single quote used in 'the' will look diffrent. Change it in the note pad and copy the code into your ABAP editor. This will sovle your problem. We are also facing the same problem from few days.

Thanks and Regards,

Bharat Kumar Reddy.V

Message was edited by: Bharat Kumar Reddy Vaka

Former Member
0 Kudos

Hi Nimesh,

i have copy your code and it looks like this:

PROGRAM DEMO_ELEMENTARY_DATA_OBJECTS.

DATA NCK1(40) type c .

NCK1 = ‘THE’.

WRITE NCK1.

Line 3 is a Mistake, it should be:

NCK1 = 'THE'. (sign ' obove the #).

Hope i can help you.

Regards, Dieter

vinod_gunaware2
Active Contributor
0 Kudos

Check there is tow statement of

Program <b>ZNTEST</b> Field

PROGRAM <b>DEMO_ELEMENTARY_DATA_OBJECTS</b>.

Change first statement report proceeding with ur report name.

regards

vinod

Former Member
0 Kudos

Hi nimesh,

1. ‘THE’.

is creating the problem.

2. <b>The QUOTES are incorrect.</b>

3. It should be (')

(the key on the left of ENTER key)

regards,

amit m.

former_member188685
Active Contributor
0 Kudos

Hi,

it is because of the quote you are using.

now check this..

'THE' is different than you code.

PROGRAM DEMO_ELEMENTARY_DATA_OBJECTS.

DATA NCK1(40) type c.

NCK1 = 'THE'.

WRITE NCK1.

regards

vijay

Former Member
0 Kudos

Hi Bharat Kumar Reddy

You got me right.

Problem solved.

Thanks.

Regards

Nimesh

Former Member
0 Kudos

Hii

there's a problem with your <b>'</b> (colon)

DATA NCK1(40) type c .

NCK1 = 'THE'.

WRITE NCK1.

copy and paste this code..it will work

Regards

Naresh