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
chriswragge
Helper I
Helper I

Pivot two tables

Hi there, 

 

I'm not sure if my subject line describes accuratly what I am trying to do, but I would like a query to turn Table A and Table B, into Table C.

 

A & B are single column tables with no values.

 

Table A

1

2

3

 

Table B

x

y

 

Table C

1 x

1 y

2 x

2 y

3 x

3 y

1 ACCEPTED SOLUTION
v-juanli-msft
Community Support
Community Support

Hi @chriswragge

In edit queries, add a Custom Column to create a Cross Join.

Open TableA, create a custom column using TableB,

7.png

 

After you click OK, you get a new column that “contains” the entire TableB as an object in each row of the TableA (as shown above).

Then all I needed to do then is expand the new column by clicking the expand button (shown above) to create all the possible combinations (shown below)

8.png

 

Best Regards

Maggie

View solution in original post

2 REPLIES 2
v-juanli-msft
Community Support
Community Support

Hi @chriswragge

In edit queries, add a Custom Column to create a Cross Join.

Open TableA, create a custom column using TableB,

7.png

 

After you click OK, you get a new column that “contains” the entire TableB as an object in each row of the TableA (as shown above).

Then all I needed to do then is expand the new column by clicking the expand button (shown above) to create all the possible combinations (shown below)

8.png

 

Best Regards

Maggie

Thanks Maggie. Worked a treat!

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!

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.

Top Solution Authors