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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
sh10
New Member

Excel Index Match to retrieve a data column based on selected value

Hello! I did a formula below in Excel to get a column of data based on the selected value in a Slicer.

For example, if a user select July in the slicer, it returns me the row of column values for July.

How can i perform this in Power BI?

 

INDEX('Cost Center AOP'!$G:$R,,MATCH($H$2,'Cost Center AOP'!$G$5:$R$5,0))

 

 

Cost Center AOP data

 

May   |    June   |      July   |     August    <---Column Name

$0            $1             $2              $3

$1            $2             $2              $2

$3            $3             $3              $3  

1 ACCEPTED SOLUTION
v-yuta-msft
Community Support
Community Support

Hi sh10,

 

You can't do this directly in power bi because all the filter is based on rows, not columns. As a workaround, you can click-> query editor-> transform-> unpivot columns as below:

Capture.PNG 

 

After applied&closed, create a slicer visual based on attribute column like below:

2.PNG 

 

Regards,

Jimmy Tao

View solution in original post

1 REPLY 1
v-yuta-msft
Community Support
Community Support

Hi sh10,

 

You can't do this directly in power bi because all the filter is based on rows, not columns. As a workaround, you can click-> query editor-> transform-> unpivot columns as below:

Capture.PNG 

 

After applied&closed, create a slicer visual based on attribute column like below:

2.PNG 

 

Regards,

Jimmy Tao

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.