‎2005 Nov 03 6:03 AM
hello,
please help me. my variable contains this text 'CA_Product', how would i get the 'CA' only. in general how would i get the letter before the underline (_). thanks.
‎2005 Nov 03 6:09 AM
Hey Donna,
Split the string using the charachter' _ ' and then u will get it into another variable.
data : DELIMITER(2) VALUE '_'.
text1 = 'CA_Product'.
SPLIT text1 AT DELIMITER INTO text2 text3.
‎2005 Nov 03 6:09 AM
Hey Donna,
Split the string using the charachter' _ ' and then u will get it into another variable.
data : DELIMITER(2) VALUE '_'.
text1 = 'CA_Product'.
SPLIT text1 AT DELIMITER INTO text2 text3.
‎2005 Nov 03 7:22 AM
‎2005 Nov 03 6:13 AM
DATA: t3(14) TYPE c VALUE 'CA_product',
string3 LIKE t3,
str3(1) TYPE c VALUE '_',
int TYPE i.
string3 = t3.
WRITE string3.
SHIFT string3 RIGHT DELETING TRAILING str3.
WRITE / string3.
SHIFT string3 LEFT DELETING LEADING space.
SKIP.
ULINE.
int = strlen( sting3 ).
Then now u can read string3 using OFFSET+0(int).