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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Ibrahim_shaik
Helper V
Helper V

One dynamic Column value and other column values are static in a Column Chart

Hi Power Bi Community,

 

I have a table in which there are three columns Index, Category, Value. In this table there are 8 rows and 1st row that is category 1 value should be dynamic it should change depending upon the date slicer.

 

I have a another table where i have created a measure. I want to create another measure and in the DAX i want to assign the measure that i have already in the table to the category 1 value as it is the requirement and for the other categories i will assign static values which does not change and I want display that measure on Column chart.

 

I applied this but the dynamic column is not displayed in the chart all the other static column values are displayed. 

 

Example: category 1 is Books it value should be dynamic(integer value) when the date slicer is selected.

 

how to achieve this, please suggest a solution.

 

Thanks & Regards,

Ibrahim

 

 

2 REPLIES 2
amitchandak
Super User
Super User

@Ibrahim_shaik, Based on what I got

If you have static Values you can use measure like

Category Value =
SWITCH(
SELECTEDVALUE('Categories'[Category]),
"Books", [Dynamic Book Sales], // Dynamic value
"Category2", 300, //static value
"Category3", 150,
0
)


or you can try all or allselected

Category Value =
SWITCH(
SELECTEDVALUE('Categories'[Category]),
"Books", [Dynamic Book Sales], // Dynamic value
"Category2", calculate([Dynamic Book Sales],all()) , //static value
"Category3", , calculate([Dynamic Book Sales],all()) ,
0
)

or

Category Value =
SWITCH(
SELECTEDVALUE('Categories'[Category]),
"Books", [Dynamic Book Sales], // Dynamic value
"Category2", calculate([Dynamic Book Sales],allselected()) , //static value
"Category3", , calculate([Dynamic Book Sales],allselected()) ,
0
)

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

Hi @amitchandak ,

 

Thank you for the response.

 

I have already tried this measure but it does not work.

 

I have added category and date in the X axis and measure in the Y axis of the column chart and when i try to filter the column chart with the date slicer it doesn't filter and dynamic column only shows the value as 1 and when I try to filter with the date slicer, column chart disappears.

 

what could be reason, why it's working?

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.