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

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
gaurangb
New Member

Use DAX variable within measure

I need to generate multiple reports from different tables. The common columns are Name,Surname and, Date. There are others as well. 

 

I have created follwoing measure for to show in card visualization based on selection.

 

M_Name_Card = IF(HASONEVALUE(TABLE1[Name]),SELECTEDVALUE(TABLE1[Name]),"Multiple")
M_Surname_Card = IF(HASONEVALUE(TABLE1[Surname]),SELECTEDVALUE(TABLE1[Surname]),"Multiple")
M_Date = FORMAT(TABLE1[Date],"Mmm'YY")
M_Date_Card = IF(HASONEVALUE(TABLE1[Date]),SELECTEDVALUE(TABLE1[M_Date]),"Multiple")

 

I need to use the same measures with other Tables, Like Table 2, Table3... in different reports.

How can I use Table name as variable and use?

 

Gb

 

1 REPLY 1
v-danhe-msft
Microsoft Employee
Microsoft Employee

Hi @gaurangb,

Based on my research, I am afraid you could not achieve this feature currently, I suggest you submit an idea in ideas forum:

https://ideas.powerbi.com/forums/265200-power-bi-ideas

 

Regards,

Daniel He

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

Helpful resources

Announcements
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.