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

Please help to debug Program

Former Member
0 Likes
456

Hi All,

I have written program in ABAP as below and getting error in row 20 that "Field F7 is unknown. it is nither in one of the spectified table nor defiened by data statement."

I am not able to debug this so please confirm that why i am getting this error and what is the issue?.

REPORT ZTEST_PROGRAM13 .

.

tables: Ztest4.

Data: f1(2) type c value 'AB',

f2 type i value 1234,

f3 type p value 12345,

f4 type f value '12E12',

f5(3) type n value '555',

f6 type d value "12456-897",

f7 type t value '1201',

f8 type x value 'BB'

begin of s1,

f1(3) type c value 'XYZ',

f2 type i value 123469587,

end of s1.

Ztest4-lifnr = 'XXX'.

Ztest4-country = 'US'.

write: / 'f1 = ''' no gap, f1 no gap, '''',

/ 'f2 = ''' no gap, f2 no gap, '''',

/ 'f3 = ''' no gap, f3 no gap, '''',

/ 'f4 = ''' no gap, f4 no gap, '''',

/ 'f5 = ''' no gap, f5 no gap, '''',

/ 'f6 = ''' no gap, f6 no gap, '''',

/ 'f7 = ''' no gap, f7 no gap, '''',

/ 'f8 = ''' no gap, f8 no gap, '''',

/ 's1-f1 = ''' no gap, s1-f1 no gap, '''',

/ 's1-f2 = ''' no gap, s1-f2 no gap, '''',

/ 'Ztest4-lifnr = ''' no gap, Ztest4-lifnr no gap, '''',

/ 'Ztest4-country = ''' no gap, Ztest4-country no gap, ''''.

clear f1,f2,f3,f4,f5,f6,f7,f8,s1,Ztest4.

write: / 'f1 = ''' no gap, f1 no gap, '''',

/ 'f2 = ''' no gap, f2 no gap, '''',

/ 'f3 = ''' no gap, f3 no gap, '''',

/ 'f4 = ''' no gap, f4 no gap, '''',

/ 'f5 = ''' no gap, f5 no gap, '''',

/ 'f6 = ''' no gap, f6 no gap, '''',

/ 'f7 = ''' no gap, f7 no gap, '''',

/ 'f8 = ''' no gap, f8 no gap, '''',

/ 's1-f1 = ''' no gap, s1-f1 no gap, '''',

/ 's1-f2 = ''' no gap, s1-f2 no gap, '''',

/ 'Ztest4-lifnr = ''' no gap, Ztest4-lifnr no gap, '''',

/ 'Ztest4-country = ''' no gap, Ztest4-country no gap, ''''.

1 ACCEPTED SOLUTION
Read only

GauthamV
Active Contributor
0 Likes
386

use single quotes here.

f6 type d value "12456-897", -> like this f6 type d value '12456-897',

1 REPLY 1
Read only

GauthamV
Active Contributor
0 Likes
387

use single quotes here.

f6 type d value "12456-897", -> like this f6 type d value '12456-897',