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

INT4 to String

andy_dingfelder3
Participant
0 Likes
911

Hello,

possible a simple question for the gurus of this forum. When i move the value of a INT4 declared variable into a string variable always a space is added at the end of the string.

Anybody can explain this behaviour?

DATA: int TYPE int4 VALUE 0,
      string TYPE string.

string = int.

The variable string contains now 3020 (hexadecimal). So why the space?

Regards,

Andy

1 ACCEPTED SOLUTION
Read only

ThomasZloch
Active Contributor
0 Likes
816

conversion integer -> string: negative values have a "-" in last position, positive values a space.

Thomas

http://help.sap.com/abapdocu_70/en/ABENCONVERSION_TYPE_IBS.htm

3 REPLIES 3
Read only

ThomasZloch
Active Contributor
0 Likes
817

conversion integer -> string: negative values have a "-" in last position, positive values a space.

Thomas

http://help.sap.com/abapdocu_70/en/ABENCONVERSION_TYPE_IBS.htm

Read only

SuhaSaha
Product and Topic Expert
Product and Topic Expert
0 Likes
816

>

> conversion integer -> string: negative values have a "-" in last position, positive values a space.

> Thomas

I wish i could give you 10 p(o)ints

Cheers,

Suhas

Read only

0 Likes
816

I just looked it up, see my link above