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

How to add multiple variables (adapt '&' to return a value)

Good Morning,

 

I was hoping someone could help me out- I apologise if this is already common knowledge- I could not find it within the forum.

 

Essentially I need to add multiple variables- however as '&' brings back True/False the variable does not produce a value-- I know the variable works as individually they return the value--

 

Below are the variables- and in an ideal world- is what id want the formula to do-- 

 

 

finno14_0-1622098532232.png

*Please note I do not have access to the data tab, nor typical calenders functions are not viable*

 

Any guidance would be great!!


Kind regards,

1 ACCEPTED SOLUTION
v-jingzhang
Community Support
Community Support

Hi @Anonymous 

 

You only need to use one '&' to combine multiple values. For example,

(Wk1-Wk4) & (Wk2-Wk1) & (Wk3-Wk2)

 

Or if you want to add a delimiter (e.g. comma) between values, you could use

(Wk1-Wk4) & "," & (Wk2-Wk1) & "," & (Wk3-Wk2)

 

'&' is a text concatenation operator while '&&' is a logic operator.

DAX syntax - DAX | Microsoft Docs

 

Regards,
Community Support Team _ Jing
If this post helps, please Accept it as the solution to help other members find it.

View solution in original post

3 REPLIES 3
v-jingzhang
Community Support
Community Support

Hi @Anonymous 

 

You only need to use one '&' to combine multiple values. For example,

(Wk1-Wk4) & (Wk2-Wk1) & (Wk3-Wk2)

 

Or if you want to add a delimiter (e.g. comma) between values, you could use

(Wk1-Wk4) & "," & (Wk2-Wk1) & "," & (Wk3-Wk2)

 

'&' is a text concatenation operator while '&&' is a logic operator.

DAX syntax - DAX | Microsoft Docs

 

Regards,
Community Support Team _ Jing
If this post helps, please Accept it as the solution to help other members find it.

Tahreem24
Super User
Super User

@Anonymous  What do you want to display in an output?

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard
amitchandak
Super User
Super User

@Anonymous , expected output is not clear to me

If you want to multiple you can create like 

 

(Wk1 -wk2) *(W3-w4)

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

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.