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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
Sri_phani
Helper III
Helper III

Cannot Identify the table that contain column

Hi team, 

 

Kindly help me with this. 

 

I executed this table measure in the DAX query view. The problem with this is, that I am unable to use this in Measure and show value in the card. the objective is to identify the rank of employees between selected dates and show it in the card. So I tried this approach of creating the virtual table and adding the columns. This works fine in the Query view, but when I try to use calculate to convert it into measure. it's saying the rank column cannot be found. 


Here is the screenshot of the DAX Query view (it's working fine) : 

 

Sri_phani_0-1722792163445.png

 

I did some search and found the data linage can effect this kind of approach. But couldn't figure out how to fix the below problem. 

I even tried removing resolve numerator and denominator and replace it with directly "Resolve" measure I created but no change. 

 

Test file - Google Sheets ( This data is exact replica of my dataset, except removed the confidentia...

 

VAR Tabled =
    SUMMARIZE(
                FILTER(
                    'Metric Table',
                    'Metric Table'[Date] <= MAX('Metric Table'[Date]) &&
                    'Metric Table'[Date] >= MIN('Metric Table'[Date]) &&
                    'Metric Table'[Site + LOB] = "Hyderabad - Rider"
                ),
                'Metric Table'[Employee Name],
                'Metric Table'[Site + LOB]
            ,
            "Resolve Numerator", SUM('Metric Table'[Resolve Numerator]),
            "Resolve Denominator", SUM('Metric Table'[Resolve Denominator]))

VAR newtable = SELECTCOLUMNS(Tabled,
			'Metric Table'[Employee Name],
			 "Resolve1", [Resolve Numerator]/[Resolve Denominator]
				)
VAR test1 = SELECTCOLUMNS(newtable,
			'Metric Table'[Employee Name], 
			"attain", [Resolve1]/0.60
				)
VAR test_filter = FILTER(test1, 
			[attain]<>BLANK()
			)
VAR Ranking = SELECTCOLUMNS(test_filter,
				'Metric Table'[Employee Name],"Rank1", 
				RANKX(test_filter, [attain],, DESC,Dense)
			)
VAR test2 =  FILTER(Ranking, 
			'Metric Table'[Employee Name] = "Santosh Kumari"
		)
VAR test4 = SELECTCOLUMNS(test2, "Only Rank",[Rank1])

RETURN
test4

 

1 ACCEPTED SOLUTION
Dangar332
Super User
Super User

Hi, @Sri_phani 

As i understood your problem you have Three slicer in page
1.  Employee Name  

2. site+LOB

3. Dates 


Try below measure 

create Measure for attain_measure

 

attain_measure=
var Numerator = SUM('Metric Table'[Resolve Numerator])
var Denominator = SUM('Metric Table'[Resolve Denominator]))
return
(divide(Numerator,Denominator))/0.60

 

Create RankX_measure for your Card visuals 
use below measure for your Card visuals

 

RankX_measure  =
var Table_ = 
addcolumn(
filter(
all('Metric Table'[Employee Name], 'Metric Table'[Site + LOB] ),
 'Metric Table'[Site + LOB] = "Hyderabad - Rider"),
"attain",[attain_measure])
return
rankx(Table_,[attain_measure],,desc,dense)

 

 

Best Regards,
Dangar

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
Dangar332
Super User
Super User

Hi, @Sri_phani 

As i understood your problem you have Three slicer in page
1.  Employee Name  

2. site+LOB

3. Dates 


Try below measure 

create Measure for attain_measure

 

attain_measure=
var Numerator = SUM('Metric Table'[Resolve Numerator])
var Denominator = SUM('Metric Table'[Resolve Denominator]))
return
(divide(Numerator,Denominator))/0.60

 

Create RankX_measure for your Card visuals 
use below measure for your Card visuals

 

RankX_measure  =
var Table_ = 
addcolumn(
filter(
all('Metric Table'[Employee Name], 'Metric Table'[Site + LOB] ),
 'Metric Table'[Site + LOB] = "Hyderabad - Rider"),
"attain",[attain_measure])
return
rankx(Table_,[attain_measure],,desc,dense)

 

 

Best Regards,
Dangar

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @Dangar332 . 

 

Thank you for responding! 

I only have employee name and Date as slicers. But the objective is to identify the rank amount particular LOB ( team). Example : total 200 employees are there. I don't need rank among 200 employees. I need rank among team of 50 employees. For that I tried above approach. Does your measure, help me with my problem?

Hi, @Sri_phani 

Please try my updated Rankx measure; it might fix your issue.

 

Best Regards,
Dangar

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @Dangar332  This worked like magic. You don't know how much relieved I am. I worked like crazy on this logic since last 2 days. Thank you very much. Have a great day!

Hi, @Sri_phani 

 

Thank you

Have a good day.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.