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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Conversion of Calculated Column to Measure

Hello! I am new to power BI and would like to transform a calculated column into a measure in order for a slicer to work. 

 

I have 2 tables: 

 

Tested                   Applicable

a                            b

a                            c

a                            d

Meaning if a is tested then it can also be applicable to b, c and d 

 

Tested        Test                  Result 

a                 line                   good

a                 circle                 bad

a                 square               same

b                 line                    bad 

c                 line                     same

 

If the user selects b, i would like for it to get the results for b for the specific test type while still getting the results for a for the others. 

 

I first decided to make a calculated column which gets the results based on test type and tested, but apparently it won't update based on the user selection. I would need it to update based on user selection. 

 

Thank you! 

3 REPLIES 3
v-alq-msft
Community Support
Community Support

Hi, @Anonymous 

 

Could you please explain the logic and show the expected result based on your original post? 

 

Best Regards

Allan

amitchandak
Super User
Super User

@Anonymous ,The information you have provided is not making the problem clear to me. Can you please explain with an example.
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
Appreciate your Kudos.

lbendlin
Super User
Super User

highlight the calculated column, save the code somewhere in a text editor, delete the calculated column, create a new measure, paste the code.

 

Then you may have to adjust it a bit depending on your circumstances as you are now moving from row context to filter context.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.