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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
snifer
Post Patron
Post Patron

sectedvalue in measure to display a graph

I created a table account

what i want to to is to create a measure in order to put in Column value of the graph,

and should be like this

if I select 11999 then  put in column value [11999] [11999 budget] [ 11999 prevyear]

if I select 58229 then  put in column value [58229 ] [58229 budget] [ 58229 prevyear]

if I select 15999 then  put in column value [15999 ] [15999 budget] [ 15999 prevyear]

if I select 89999 then  put in column value [89999 ] [89999 budget] [ 89999 prevyear]

for every selection must appear 3 column 

 

those are measure already made [11999] [11999 budget] [ 11999 prevyear]

I try use SELECTEDVALUE but  I can't make it work

 

 

 

 

Capture.PNG

1 ACCEPTED SOLUTION
tex628
Community Champion
Community Champion

Change the ";" to ","

We are using different delimiters.


Connect on LinkedIn

View solution in original post

3 REPLIES 3
tex628
Community Champion
Community Champion

Make sure you have measures for all of your values,
then make 3 measures:

Measure1:

Amount = 
IF(SELECTEDVALUE([Account])="11999" ; [11999] ;
IF(SELECTEDVALUE([Account])="15999" ; [15999] ;
IF(SELECTEDVALUE([Account])="58229" ; [58229] ;
IF(SELECTEDVALUE([Account])="89999" ; [89999] ;
BLANK()
))))

Measure2:

Budget = 
IF(SELECTEDVALUE([Account])="11999" ; [11999Budget] ; 
IF(SELECTEDVALUE([Account])="15999" ; [15999Budget] ; 
IF(SELECTEDVALUE([Account])="58229" ; [58229Budget] ; 
IF(SELECTEDVALUE([Account])="89999" ; [89999Budget] ; 
BLANK() 
))))

Measure3:

Budget = 
IF(SELECTEDVALUE([Account])="11999" ; [11999prevyear] ; 
IF(SELECTEDVALUE([Account])="15999" ; [15999prevyear] ; 
IF(SELECTEDVALUE([Account])="58229" ; [58229prevyear] ; 
IF(SELECTEDVALUE([Account])="89999" ; [89999prevyear] ; 
BLANK() 
))))

Connect on LinkedIn

@CTE 

 

Current year =
IF(SELECTEDVALUE('VISUAL SELECTOR'[code])="11999";UploadAccountsCurrentyPeriod[11999] ;
IF(SELECTEDVALUE('VISUAL SELECTOR'[code])="15999" ; UploadAccountsCurrentyPeriod[15999];
IF(SELECTEDVALUE('VISUAL SELECTOR'[code])="58229"; UploadAccountsCurrentyPeriod[58299] ;
IF(SELECTEDVALUE('VISUAL SELECTOR'[code])="89999"; UploadAccountsCurrentyPeriod[89999] ;
BLANK()
))))
 
 
I try create a measure from your suggestion but there are a syntax error
 
Capture.PNG
tex628
Community Champion
Community Champion

Change the ";" to ","

We are using different delimiters.


Connect on LinkedIn

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

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