Boomi Buzz: Blogs & Events
Boomi Training & Certification
About the Community
to create and rate content, and to follow, bookmark, and share content with other members.
I'm noticing something strange when i try to strip characters '-' and "." from a phone number in a user defined function. I am receiving empty results. Any suggestions?
Question asked by
on Mar 16, 2012
on Apr 12, 2012 by ted.sager
No one else has this question
Mark as assumed answered
This content has been marked as final.
Show 4 comments
(Required, will not be published)
Mar 20, 2012 9:51 AM
Are you using the Remove or Replace functions?
If so, "." and "-" are special characters in Regex. You need to use an escape character, or else their special meaning in used.
Just use a backslash to escape them: i.e. "\." "\-" sans quotes. I believe you can also use brackets, .
The reason nothing was coming out is that the "." matches all characters except for line breaks I believe, so it was matching on all your data.
Apr 11, 2012 2:32 PM
Oh okay, thank you...
I also attempted to use the following java script:
NewPhone = Phone.replace( /\D/g, '' );
And it still isn't working
Apr 11, 2012 2:34 PM
output = input.replace(()/[^a-z A-Z 0-9]+/g,''.);
Apr 12, 2012 3:39 PM
Do you get an error when you used the above, or did it just not replace correctly?
Also, you can try using the String Replace Map function, with [\D] in the "String to Seach" field. That will match all non numeric characters, just like the above.
2 people found this helpful
Retrieving data ...
7 Habits of the Successful Boomi Developer
Development standards and folder organization
Dell Boomi's Planned Improvements to its Hosting Environment
How to Use the Mail (IMAP) Connector
Salesforce connector - Bulk API v2