Merge Columns
Combine two or more columns into a single string column using a delimiter. Configure multiple merge rules in one operation while preserving source columns.
Merge Columns combines two or more columns into a single new string column using a separator you choose. Every value in the selected columns is cast to string, joined with the delimiter, and stored in a new column you name. The source columns are unchanged.
You can configure multiple merge rules in one operation, each producing a different output column.
When to Use Merge Columns
- Full name column. Combine
first_nameandlast_nameinto a singlefull_namefield for CRM exports or display. - Composite identifier. Join
region,product_id, andyearinto a single key for joins or reporting. - Formatted address. Merge
street,city,state, andzipinto oneaddresscolumn for downstream systems. - Transaction label. Combine
transaction_type,account_number, anddateinto a readable audit log column. - Unique lookup key. Create a
customer_product_keyby merging two identifiers before a lookup join.
Sample Dataset
The examples in this doc use the Edilitics sample orders dataset. Download it to follow along in your own workspace.
edilitics_sample_orders.csv
Sample orders dataset for hands-on practice · 500 rows
Relevant columns for Merge Columns examples:
Prop
Type
Delimiters
The delimiter is the character inserted between values when columns are joined.
| Option | Character | Example output |
|---|---|---|
| Space | | John Smith |
| Tab | \t | John Smith |
| Pipe | | | John|Smith |
| Hyphen | - | John-Smith |
| Underscore | _ | John_Smith |
| Custom | any | type your own |
The Delimiter dropdown is a creatable select. Select one of the five options or type any character or string to use it as a custom delimiter.
How to Apply Merge Columns
Open the Merge Columns operation
In your Transform pipeline, click Add Operation and select Merge Columns from the operation list.
Select columns to merge
In the Select Columns to Merge section, choose the columns to combine. The first two column slots appear by default. Click Add Column to add more input columns to this merge rule.
You can remove a column slot by clicking its remove icon. A minimum of two columns is required.
All column types are supported. Non-string columns are automatically cast to string before joining.
Select a delimiter
Choose the separator from the Select a Delimiter dropdown. Options: Space, Tab, Pipe, Hyphen, Underscore. To use a custom separator, type it directly into the dropdown.
Name the output column
Type a name in the New Column Name field. The name must:
- Contain only letters, numbers, and underscores
- Not start with
__or a number - Not already exist in the dataset or in another merge rule configured in this operation
Click Done
Click Done to add this merge rule to the list above the configuration panel. The output column name is now reserved and cannot be reused in another rule.
To configure another merge, click Add Merge Rule and repeat the steps above.
Save the operation
Click Save & Preview. Edilitics applies all merge rules and adds the new columns to the dataset. A success toast confirms: "Columns merged. Preview updated with the new composite column."
Save & Preview is disabled until at least one merge rule has been submitted with Done.
Verify in the preview
Check the new column in the preview. Confirm the delimiter is correct and that values from all source columns appear in the expected order.
Before and After
Two merge rules configured in one operation:
first_name+last_namewith Space delimiter =full_nameregion+order_idwith Hyphen delimiter =region_order_key
Input:
| first_name | last_name | region | order_id |
|---|---|---|---|
| Jane | Lee | East | 1001 |
| Marco | Silva | West | 1002 |
Output:
| first_name | last_name | region | order_id | full_name | region_order_key |
|---|---|---|---|---|---|
| Jane | Lee | East | 1001 | Jane Lee | East-1001 |
| Marco | Silva | West | 1002 | Marco Silva | West-1002 |
Source columns unchanged. Two new string columns added.
Code Equivalent
SELECT
*,
first_name || ' ' || last_name AS full_name,
region || '-' || CAST(order_id AS TEXT) AS region_order_key
FROM orders;import polars as pl
df = df.with_columns([
pl.concat_str([pl.col("first_name"), pl.col("last_name")], separator=" ").alias("full_name"),
pl.concat_str([pl.col("region"), pl.col("order_id").cast(pl.String)], separator="-").alias("region_order_key"),
])After Save & Preview, the pipeline shows a DQ delta badge on this step - green if the table score improved, red if it dropped. See Data Quality Scoring for how scores are calculated.
After Save & Preview, the pipeline shows a DQ delta badge on this step - green if the table score improved, red if it dropped. See Data Quality Scoring for how scores are calculated.
Operation Reference
Prop
Type
Frequently Asked Questions
Next Steps
Split Columns
Reverse a merge by splitting one column into multiple on a delimiter.
Find & Replace
Clean up values in the merged column before using it as a key.
Drop / Rename Columns
Rename the merged column or drop source columns you no longer need.
Join
Use the merged composite key to join this dataset to another.
Need help? Email support@edilitics.com with your workspace, job ID, and context. We reply within one business day.
Last updated on
Cast Data Types
Convert column data types without code. Change string to integer, datetime to date, or boolean. Available target types adapt to your destination database.
Split Columns
Split a column into multiple new string columns by delimiter or regex. Define output column names and configure multiple split rules in one operation.