Saturday, Jun. 24, 2017

Parse Special characters in a string using a workflow

Written By:

|

January 14, 2013

|

Posted In:

Requirement

The requirement is to collect the account data and send it accross the external system using EAI Integration. In order to gather the account details we need to query the name in Siebel DB which can also contain special characters. Focussing on the configuration part i.e. to parse special characters in a Account name.

For example, Account Name can be:
AmitKumarSh’arma (Apostrophe), AmitKumar”Sharma(Double Quotes), AmitKumar#Sharma, AmitKumar$harma,Amit(Kumar)Sharma, AmitKumarSh’arma, Amit(Ku”mar)Sharma,Amit$(Ku”mar)S#harma, AmitKumar(Sh’a)rma.
We need to parse these characters and provide a scriptless solution. Although there are alternatives in escript such as functions called replace(), join() used along with split() but the need was a scriptless solution.

Solution

Follow the below scriptless solution to implement this requirement using a workflow process.
1. In Siebel Tools, create a new workflow process based on “Account” BO and workflow mode as “Service Flow”.

special characters1

Create Custom process properties as below

AccountName       type = String
Name                   type = String
Charfound             type = String
Length                 type = Number
Number Of Rows  type = Number
PrefixName          type = String
SuffixName          type = String

2. Configure the Search Character Step as below:

special characters2

For reference the values are  – InStr([&AccountName], “‘”) and Len([&AccountName])
3. Configure the Break Account Name Step as below

special characters3

For reference the values are  – Left([&AccountName], [&Charfound]) and Right([&AccountName],[&Length]-[&Charfound])

4. Configure the Concatenate Step as below:

special characters4

For reference the values is  – [&PrefixName]+”‘”+[&SuffixName]

5. Configure the Query Account Step as below:

special characters5

For reference the values is – “[Alias] ='”+ [&Name]+”‘”
Alias is the field name at the BC level:

special characters6

6. Configure the decision step Special character step as below:
Set the Type as Condition for “Yes” pointer and Set the type as Default for Connector 8.
Define the below condition on “Yes”

special characters7

7. Configure the Query Account Name step as below

special characters8

For reference the value is – “[Alias] ='”+ [&AccountName]+”‘”

special characters9

8. Supply the “Default String” property for process property called “Account Name” with the input string for testing in debug mode. You will see that the special characters are parsed as below
Name containing apostophe are parsed via the path Start->Search Character -> Special Character -> Query Account Name ->End

Name containing other special characters are parsed via path Start->Search Character -> Special Character ->Break Account Name -> Concatenate -> Query Account ->End

For Scripted solution you can visit :

How to parse/ prevent input of special character
Special / Junk Character Removal From Data

 



Share This Article

About Author

Gurdeep

Hi, I am sharing my experience to alleviate beginners with open UI and HI version of Siebel CRM. I work in Sun Life Financials and can be reached via IT Tool box as well. Thanks.

  • P S

    Hi,

    Which BS is used here for Search Character,Break Account Name ,Concatenate..?