Forum Discussion
How can I get a column to delimit as seperate rows ?
- 1 year ago
Hey EaglesTony,
Based on your requirement to split comma-separated owner values into individual rows, here are the recommended approaches:
Method 1: Using Power Query Editor
- Select the target table in Power BI Desktop and click "Transform data" to open Power Query Editor
- Navigate to the Owners column and select it by clicking on the column header
- Access the Split Column feature by going to Home tab → Split Column → By Delimiter
- Configure delimiter settings:
- Choose "Comma" as the delimiter
- Select "Each occurrence of the delimiter" option
- Choose "Rows" instead of "Columns" in the advanced options
- Clean up the data by selecting the Owners column and applying Transform → Trim to remove any extra spaces
- Apply changes by clicking "Close & Apply" to return to the main Power BI interface
Method 2: Using DAX
If you prefer a calculated table approach:
ExpandedTable =
ADDCOLUMNS(
SELECTCOLUMNS(
GENERATESERIES(1, MAXX(YourTable, LEN(YourTable[Owners]) - LEN(SUBSTITUTE(YourTable[Owners], ",", "")) + 1)),
"RowNumber", [Value]
),
"Application Code",
LOOKUPVALUE(
YourTable[Application Code],
YourTable[Application Code],
YourTable[Application Code]
),
"Owners",
TRIM(
PATHITEM(
SUBSTITUTE(YourTable[Owners], ",", "|"),
[RowNumber]
)
)
)
The Power Query method (Method 1) is strongly recommended as it provides the most robust and maintainable solution for your merge process requirements.Fixed? ✓ Mark it • Share it • Help others!
Best Regards,
Jainesh Poojara | Power BI Developer
Thank you!...Exactly what I needed and I did use option 1, since I have to merge data to it.
Sounds good, Happy to contribute!