12-09-2008 10:53 AM
how to seperate number .....
for eg 'hsl01'
menas i need to seperate hsl / 01
12-09-2008 10:56 AM
hi,
Search for sy-num in string.
and find the posiition and use split command tp split the string at that position.
Hope it will help you.
Regards
Manjari.
12-09-2008 10:56 AM
Search SCN with the search term: SPLIT, And from Now on make it a habit of searching in SCN before posting a question.
12-09-2008 10:58 AM
hi,
Declare the variable of type N and move the value to the variable. Only number get moved.
Data : Value(2) TYPE N,
Value1(10) TYPE C.
Value = Value1 ='Test01'.
Write value.
REPLACE ALL OCCURRENCES OF value IN VALUE1 WITH ''.
Write value1.
12-09-2008 10:59 AM
Hi,
Use the following logic
data : text type string value 'HSL01'.
data : g_text1 type string,
g_text2 type string,
g_text3 type string.
data : g_sep type c value '/'.
start-of-selection.
split text at '0' into g_text1 g_text2.
concatenate g_text1 g_sep g_text2 into g_text3. " the g_text3 will contain the string as required
Regards,
Mansi.
Edited by: SAP USER on Dec 9, 2008 12:00 PM
Edited by: SAP USER on Dec 9, 2008 12:01 PM
12-09-2008 11:03 AM
12-09-2008 11:02 AM
Check sy-abcde in string and separate alphabets and numbers.
Regards,
Aparna.
12-09-2008 11:13 AM
hi,
Declare the variable of type N and move the value to the variable. Only number get moved.
Data : Value(2) TYPE N,
Value1(10) TYPE C.
Value = Value1 ='Test01'.
Write value.
REPLACE ALL OCCURRENCES OF value IN VALUE1 WITH ''.
Write value1.
12-09-2008 11:05 AM
Hi
If you have always HSL as the first three chars then try this one
data : var1 type string
var2 type string
and lets say var = HSL01
then
var1 = var+0(3) gives you HSL
var2 = var+3(2) gives you 01
concatenate var1 '/' var2 into var (gives you HSL/01)
Regards
Ramchander Rao.K
12-09-2008 11:08 AM
12-09-2008 11:12 AM
12-09-2008 11:18 AM
Hi.
As other mentioned before: Please search before you ask basic questions in the SCN. I will lock this thread.
Best regards,
Jan Stallkamp