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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
mpicca13
Resolver IV
Resolver IV

Concatenate currency symbol with price and retain conditional formatting

I have a fact table which contains 2 columns, selling price(Currency Type) and Currency (String).

currency can either be (USD, CAD, MXN).

 

Is it possible with DAX to concatenate the two and still retain conditional formatting in a matrix for price ranges?

I would like to do this without further normalizing into a seperate dim_currency table.

4 REPLIES 4
v-yiruan-msft
Community Support
Community Support

Hi @mpicca13 ,

You can follow the below steps to achieve it, you can find the details in below screenshot:

1. Create a measure to set the color by conditions base on field [Selling price]

2. Create a measure or calculated column to concatenate the field [Selling price] and [Currency]

Concatenate = CONCATENATE(CONCATENATE('Table'[Currency]," "),'Table'[Selling price])//calculated column​
Measure= CONCATENATE(CONCATENATE(MAX('Table'[Currency])," "),MAX('Table'[Selling price]))

3. Set the conditional formatting for the concatenate field use the conditional formatting measure

Concatenate currency symbol with price and retain conditional formattin.JPG

Best Regards
Rena
Community Support Team _ Rena Ruan
If this post helps, then please consider Accept it as the solution to help the other members find it more.

 

 

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

@v-yiruan-msft Thank you for the suggestions. Calculated columns are not an option here, that dataset is too large. I've tried with the  easure as you suggested but the performance is very bad. Resulted in Dax timing of 37,000 MS.

anandav
Skilled Sharer
Skilled Sharer

You can use Condition Formatting based on the Currency field for the new concatenated field.

 

Not sure whether this is what you are after or I am not getting your requirement.

 

amitchandak
Super User
Super User

@mpicca13 , if you append like a text then it will become text. You can not do numeric operations after that. If possible keep the currency column in a separate column. If there is a single currency then you can use option under format in Measure/column tools

Join us as experts from around the world come together to shape the future of data and AI!
At the Microsoft Analytics Community Conference, global leaders and influential voices are stepping up to share their knowledge and help you master the latest in Microsoft Fabric, Copilot, and Purview.
️ November 12th-14th, 2024
 Online Event
Register Here

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.