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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Calculated table basesed on a union of selects of constants or measures

Hello,

 

Is it possible to mak a calculated tabel that's made of constant values

 

Table = UNION(
SELECT "Value 1" AS Column;
SELECT "Value 2";
SELECT "Value 3";
SELECT "Value 4"
)
that would result in:
 
Table.jpg
 
Of course I could make a new table using "Enter data"

Enter_Data.jpg
 
but I want to use measures in stead of contstant values
 
Table = UNION(
SELECT Measure1 AS Column;
SELECT Measure2;
SELECT Measure3;
SELECT Measure4
)
 In this way it becomes a dynamic table.
 
 
Thanks,
 
R.W.
4 REPLIES 4
Anonymous
Not applicable

@Anonymous 

You can use curly braces { }, it's a table expression that allows you to enter any value on each row, as well as measure. 

 

Paul Zheng _ Community Support Team
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

amitchandak
Super User
Super User

@Anonymous , one or more you can do like

union(
selectcolumns(table1,"ColA", table1[Column A],"ColA", table1[Column B],"ColF", table1[Column F]),
selectcolumns(table2,"ColA", table2[Column A],"ColA", table2[Column B],"ColF", table2[Column F])
)

 

Or you can use summarize in place of selectcolumns

Balance Sheet = union(SUMMARIZE(Sales,Sales[Brand],"Col1",sum(Sales[Sales]),"Col2",sum(Sales[COGS]),"sort",COUNTROWS(Sales))
,SUMMARIZE(Sales1,Sales1[Brand],"Col1",sum(Sales1[Sales]),"Col2",sum(Sales1[COGS]),"sort",COUNTROWS(Sales1)) )

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

@amitchandak 

 

Thanks,

But its not what I'm looking for.
I don't want the records comming directly from tables.
I want de values be constants and/or Measure values.

 

R.W.

@Anonymous 

 

Try this 

Table = {[Measure],[Measure 2]}

out.JPG 



Did I answer your question? Mark my post as a solution!
Appreciate with a kudos
🙂


Regards,
Nandu Krishna

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 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.