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: 

purpose of using string field

Former Member
0 Kudos

how to use string field and its purpose...

5 REPLIES 5

Florian
Active Contributor
0 Kudos

I'm not sure where you want to go to..

A string is an awesome tool to handle data. It is always in the length you need, you can get a lot of thing in it, not only words, binar data and stuff like that. Just image you need to put a PDF attached to a mail. Where do you save the pdf... yes, it's an XSTRING.

Another thing is, you want to give a clue where tax is lower than other positions. There might be orders with mor than 100 positions in. So a Char255 won't help you out easily...

Regards

Florian

vladimir_erakovic
Contributor
0 Kudos

Use string when you don't know the length, when you need to CONCATENATE ... INTO string .. and for variables that hold text messages..

Former Member
0 Kudos

Hi,

Click here to read documentation on string.

It will be very useful to you pls check.

Regards,

Alenlee MJ

Former Member
0 Kudos

STRING: Character string with variable length This data type can be used only in types (data elements, structures, table types) and domains. In the dictionary a length can be specified for this type (at least 256 characters). It can be used in database tables only with restrictions. For a description of them, refer to the documentation of the ABAP statement 'STRING'. In ABAP, this type is implemented as a reference to a storage area of variable size. The system proposes 132 characters as default for the output length. You cannot attach search helps to components of this type.

SSTRING: Short character string with variable length. In the Dictionary the number of characters can be specified for this type (from 1 to 1333). This data type can be used only in types (data elements, structures, table types) and domains. It can be used in database tables. To do so, refer to the documentation of the ABAP statement 'STRING'. In ABAP, this type is implemented as a reference to a storage area of variable size. String fields of this type can be used in indexes and in the WHERE condition of a SELECT statement. You cannot use them in table keys

hiriyappa_myageri
Participant
0 Kudos

Hi Vasan,

If you defined a variable as a string  variable means it can hold values of any type like char,Decimals,Special characters,numeric.

Suppose you can take websites address that will be string it.

hope you got it.

Regards,

Hiriyappa.