‎2007 Dec 14 11:59 AM
Dear ALL,
Am just learning SAP ABAP. I would like to know the use of String data type in SAP. When and where we use it and how do we maintain it?. Thanks to ALL in anticipation.
‎2007 Dec 14 2:42 PM
Hi Bhaskar,
You use generally use the string data type when you dont know how much wil be the length of your character field. A string may consist of normal as well as Special character.
You can define the string as DATA : string TYPE string.
Regards
Sourabh Verma
‎2007 Dec 14 12:05 PM
Hi Bhaskar,
data : str type string.
SSTRING 1-255 Character string string
STRING 256-... Character string string
The type SSTRING is available as of release 6.10 and it has a variable length. Its maximum length must be specified and is limited to 255. The advantage of this type compared with CHAR, is that it is assigned to the ABAP type string.
Check the below link for more information:
http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb2fd9358411d1829f0000e829fbfe/content.htm
<b>Kindly Reward points if you found this reply helpful</b>,
Cheers,
Chaitanya.
‎2007 Dec 14 2:42 PM
Hi Bhaskar,
You use generally use the string data type when you dont know how much wil be the length of your character field. A string may consist of normal as well as Special character.
You can define the string as DATA : string TYPE string.
Regards
Sourabh Verma
‎2007 Dec 14 4:17 PM
by default data type of string is Char255.
and its used tranfer data to files,
performing the concatinate fun. on chars,
holding the text data, etc...
declaration:
data: lv_str type string.
‎2007 Dec 14 10:37 PM
Hi,
String data type is used to hold the string of dynamic length.
Declaration:
__________
DATA name1 TYPE string.
Cheers,
Hakim
Mark all useful answers