DAX to change the content of a field?

jsabo

New Member
Joined
May 27, 2014
Messages
17
Hey guys,

Putting together a project which will mash up our company data with publicly available data from congress. I am putting together a little information section of the report which will have the Name, Party, State etc. of the selected Congressman. But I do not want the text to be populated unless a selection on the filter has been made. I tried the below with a calculated column, but it didn't work:

Code:
Name_Dynamic = if(COUNTROWS('Legislators - ALL API') > 1, "Select a Congressman", 'Legislators - ALL API'[name])

any ideas?
 

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off
You need a measure, not a calculated column. If you put this measure in a pivot table and then filter the correct table, it should work
 
Upvote 0

Forum statistics

Threads
1,215,064
Messages
6,122,937
Members
449,094
Latest member
teemeren

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top