Transform seperated string to list
Function: Transform seperated string to list
This action helps you convert a single piece of text (a string) that contains multiple items separated by a specific character into a list of individual items. This is useful when you receive data in a combined format and need to work with each part separately.
Input
- Seperated string (STRING, Required): The text you want to split into a list. This text should contain multiple values separated by a specific character.
- Seperator (STRING, Required): The character or symbol that divides the items within your "Seperated string". For example, if your string is "apple,banana,orange", the separator is a comma (,).
Output
- Result (ARRAY): The name of the variable where the newly created list of items will be stored. By default, this variable will be named "SEPERATED_LIST", but you can choose a different name. The content of this variable will be a list (array) of strings.
Execution Flow
Real-Life Examples
Here are some ways you can use the "Transform seperated string to list" action:
Example 1: Processing a list of email addresses
Imagine you have a text field where users can enter multiple email addresses, separated by semicolons. You want to send an email to each of these addresses.
- Inputs:
- Seperated string: [email protected];[email protected];[email protected]
- Seperator: ;
- Result: EmailList
 
- Seperated string: 
- Result: A new variable named EmailListis created, containing the list:["[email protected]", "[email protected]", "[email protected]"]. You can then loop through this list to send individual emails.
Example 2: Analyzing product tags from a database field
Suppose your product database stores product tags as a single string, with each tag separated by a pipe symbol (|). You need to display these tags individually on a product page.
- Inputs:
- Seperated string: Electronics|Gadgets|Smart Devices|New Arrivals
- Seperator: |
- Result: ProductTags
 
- Seperated string: 
- Result: A new variable named ProductTagsis created, containing the list:["Electronics", "Gadgets", "Smart Devices", "New Arrivals"]. This list can then be used to display each tag as a separate item.
Example 3: Breaking down a user's selected preferences
A user selects several interests from a form, and these are saved as a comma-separated string in their profile. You want to use these preferences to personalize their experience.
- Inputs:
- Seperated string: Sports,Reading,Travel,Cooking
- Seperator: ,
- Result: UserInterests
 
- Seperated string: 
- Result: A new variable named UserInterestsis created, containing the list:["Sports", "Reading", "Travel", "Cooking"]. You can now use this list to recommend relevant content or products.