Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
GCGradwell
Helper I
Helper I

Concatenate data into new column using heirarchies

Hi,

 

I am trying to create a new column which concatenates data from two different columns. These columns are in different tables and are linked to each other by relationships within Power BI.

 

I want to concatenate Customer ID and Department. Customer ID is in the same table as product. Products are categorized by product class and each product class is a member of a department.

 

Thread 3 img 2.png

 

 

 

 

Many thanks,

 

Greg

1 ACCEPTED SOLUTION
chrisu
Responsive Resident
Responsive Resident

As stated above, you'd need a calculated column.  In my own data with a similar setup (pulling the "one" side to a "many" side of a relationship two tables away), I was able to do this using a single formula that looks like this:

 

IDDepartment = CONCATENATE(Invoices[Customer ID], RELATED('Product Class'[Department]))

 

 

View solution in original post

3 REPLIES 3
chrisu
Responsive Resident
Responsive Resident

As stated above, you'd need a calculated column.  In my own data with a similar setup (pulling the "one" side to a "many" side of a relationship two tables away), I was able to do this using a single formula that looks like this:

 

IDDepartment = CONCATENATE(Invoices[Customer ID], RELATED('Product Class'[Department]))

 

 

Fantastic! Excellent solution, I really appreciate the help.

 

Massive thanks!

 

Greg

ankitpatira
Community Champion
Community Champion

@GCGradwell i think you need to make use of dax calculated columns. so first make use of lookupvalue function to create a calculated column in product details table that contains department name. then use related() function of dax to create calculated column in Invoices table that contains department name. then simply use concatenate() function for customer id and department in invoices table.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.