Data Management
Slice Variable
Extract portions of data from variables
The Slice Variable block allows you to extract specific portions of variables, such as parts of text strings or segments of lists.
Inputs
☐ Variable Name (Required)
The name of the variable you want to slice.
Good Examples:
- “emailText”
- “productList”
- “description”
☐ Start Index (Required)
The position where the slice should begin (starts at 0).
☐ End Index (Optional)
The position where the slice should end (exclusive).
Slicing Rules
Description: Define how the variable should be sliced.
Features:
☐ Start from beginning (index 0)
☐ End optional (slice to end if omitted)
☐ Works with text and lists
Example: “hello” with start:1, end:4 becomes “ell”
Usage Examples
1. Email Username
Variable
email
Start0
End8
Extract username from email address
2. List Selection
Variable
productList
Start0
End5
Get first 5 items from list
3. Text Trimming
Variable
description
Start0
End50
Shorten text to first 50 characters
Notes
- Check variable length before slicing
- Start index must be less than end index
- Indexes start at 0
- End index is optional