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: 

Error:Literals that take up more then one line not permitted

Former Member
0 Kudos

Hi All,

We are going for upgrade from 4.6 to ECC6.0,where i am getting error 'Error:Literals that take up more then one line not permitted' in below data declaration.

DATA: HEADER(255) TYPE C VALUE '

........1........2........3........4........5........6....+....7..

......8........9........0........1........2........3....+....4....

....5........6........7........8........9........0........1.....

...2........3........4....+....5....'.

----


Please help.

Thanks

Mohit

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi,

once the quotes is opened it has to be closed in the same line. If the length is not enough split and concatenate


DATA: HEADER1(255) TYPE C VALUE ' ........1........2........3........4........5........6....+....7',
DATA: HEADER2(255) TYPE C VALUE ' ......8........9........0........1........2........3....+....4....',
DATA: HEADER3(255) TYPE C VALUE ' ....5........6........7........8........9........0........1.....',
DATA: HEADER4(255) TYPE C VALUE ' ...2........3........4....+....5....'.

data: header(255) type c.

concatenate header1 header2 header3 header4 into header.

3 REPLIES 3

Former Member
0 Kudos

Hi,

once the quotes is opened it has to be closed in the same line. If the length is not enough split and concatenate


DATA: HEADER1(255) TYPE C VALUE ' ........1........2........3........4........5........6....+....7',
DATA: HEADER2(255) TYPE C VALUE ' ......8........9........0........1........2........3....+....4....',
DATA: HEADER3(255) TYPE C VALUE ' ....5........6........7........8........9........0........1.....',
DATA: HEADER4(255) TYPE C VALUE ' ...2........3........4....+....5....'.

data: header(255) type c.

concatenate header1 header2 header3 header4 into header.

former_member404244
Active Contributor
0 Kudos

hi,

If any of the quotes is missing, you get such an error. In your case they are not closed in one line.

Regards,

Nagaraj

Former Member
0 Kudos

Put them all on one line.

Go to the end of line ....5........6........7........8........9........0........1..... and press DELETE

Go to the end of line ......8........9........0........1........2........3....+....4.... and press DELETE

Go to the end of line ........1........2........3........4........5........6....+....7.. and press DELETE

Go to the end of line DATA: HEADER(255) TYPE C VALUE ' and press DELETE.

Then syntax check.