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

Unicoe Errors

Former Member
0 Likes
613

Hello ABAPpers,

I am getting the following unicode errors in the report while executing UCCHECK transaction.

1. "SY-TABIX" must be a character-type data object (data type C, N, D, T or

STRING).

for

SHIFT sy-tabix LEFT DELETING LEADING space.

2. "V_RECCTR" must be a character-type data object (data type C, N, D, T or

STRING).

for

DATA: v_recctr TYPE p,

SHIFT v_recctr LEFT DELETING LEADING space.

Please suggest the correct solution to overcome this unicode error.

Thanks and Regards,

Rahul

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
574

Hi,

this will give you unicode errors because you are trying to use the statement shift with i,p,f type variable.... you are not supposed to use shift with these data type variables... instead you can write a logic or move the values of that variable to the string type and do the shift....

copy and paste the code given below will resolve you issue.....

data w_str type string.

1) 
move sy-tabix to w_str.
SHIFT w_str LEFT DELETING LEADING space.
move w_str to sy-tabix.


2)
DATA: v_recctr TYPE p,
move v_recctr to w_str.
SHIFT w_str LEFT DELETING LEADING space.
move w_str to v_recctr.

Regards,

Siddarth

3 REPLIES 3
Read only

amit_khare
Active Contributor
0 Likes
574

none of these Values will have space as the leading value, then why these statements are required..?

Read only

Former Member
0 Likes
575

Hi,

this will give you unicode errors because you are trying to use the statement shift with i,p,f type variable.... you are not supposed to use shift with these data type variables... instead you can write a logic or move the values of that variable to the string type and do the shift....

copy and paste the code given below will resolve you issue.....

data w_str type string.

1) 
move sy-tabix to w_str.
SHIFT w_str LEFT DELETING LEADING space.
move w_str to sy-tabix.


2)
DATA: v_recctr TYPE p,
move v_recctr to w_str.
SHIFT w_str LEFT DELETING LEADING space.
move w_str to v_recctr.

Regards,

Siddarth

Read only

Pawan_Kesari
Active Contributor
0 Likes
574

>

> Hello ABAPpers,

>

> I am getting the following unicode errors in the report while executing UCCHECK transaction.

>

> 1. "SY-TABIX" must be a character-type data object (data type C, N, D, T or

> STRING).

> for

> SHIFT sy-tabix LEFT DELETING LEADING space.

>

>

>

> 2. "V_RECCTR" must be a character-type data object (data type C, N, D, T or

> STRING).

> for

>

> DATA: v_recctr TYPE p,

> SHIFT v_recctr LEFT DELETING LEADING space.

>

> Please suggest the correct solution to overcome this unicode error.

>

> Thanks and Regards,

> Rahul

DATA l_tmp TYPE string.

l_tmp = sy-tabix.
condense l_tmp