Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I have a input data which has a special character like
"maths*science*English"
my ouput should have data like
science
English
the position of the special character is not fixed and I should consider the occurrence of special character based on the other column i.e., if the other column has data like 3 I should consider the 3rd occurrence of the special character.
Thanks in Advance,
Lmit
If there is only one special string *
row7.test.contains ("*")
?
StringHandling.EREPLACE(row7.test, "*", "")
:row7.test
or
if you have multiple special characters use the code in routines. so it will and , gives you good result.
Manish
@lmit ,check the below example. works fine for your case.
@manodwhb thanks for your reply
I cant use tnormalize component because I have to sometimes consider the data before the special character or in between special character I need only part of the string Like
if my data is "ma*thsSci*eng"
for some cases I need to consider my output to be only thsSci or eng
I don't want to increase the records
Thanks,
lmit
Hi Manish,
I tried your code but it will replace special character or will displace the string.but I need part of the string based on special character
Thanks,
lmit
@manodwhb thanks for your code its displaying "thsSci"
but how about "eng" in the string
Code displays data from first occurrence to second occurrence how can I make it generic ?
Thanks,
lmit
@lmit ,can you explain with data what exactly do you want?
@manodwhb , my requirement is
source file :
id, data, position field
1, abc*dfec*eng, 1
2, abc*dfec*eng*math, 3
output should be
1,dfec
2,math
Based on the position field value , the data column should have the data
for example 2 id , the position field is 3 which means the data in data column should start from 3 occurrence of the special character and should end till the next occurrence
Hope I explained your properly
Thanks,
lmit