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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
MJALARI
Frequent Visitor

Need help to create index when we have multiple columns from multiple tables as a measure

i have three tables dimregion, dimchannel and factsales. i need to take multiple columns from these two tables . only one column from fact, that is sales. i want to use here matrix visual. i have 6 columns from dim region and dim channel as rows. and measure as sales as i mentioned. sales order by desc need to create ranking. it worked fine when i use only one column in the table as row defined in matrix. but i have now 5 other columns to keep as row. after drag and drop these columns ranking is not coming correctly.

 

 

this is the function i used here Rankx(allselected(dimregion), calculate(Sum(Sales)),,desc,Dense)

 

DIM CHANNEL

 

CHANNELID  CHANNELNAME

101                channel1

102                channel2

103                channel3

 

DIM region

 

Region ID          region          city    state         country        

101                   southregion   A         S1           C1

102                   north              B          S2          C2

103                   east                C          S3          C3

104                     west               D        S4          C4

 

Fact sales

 

Regionid   channelid  sales

101             101               50000

102                102            100000

103             103                150000

103              104                2000

 

Matrix visual should contain

 

Channelname , Region   , City ,state, country, sales ,rank

 

for creating rank i need help

3 REPLIES 3
v-angzheng-msft
Community Support
Community Support

Hi, @MJALARI 

 

Could you please consdier sharing more details about it or a simple sample file without any sesentive information?

To draw a simple picture to show your expected visual so that i may work out with a workaround.

MJALARI
Frequent Visitor

@Greg_Deckler  I have added more details now. please help. 

Greg_Deckler
Super User
Super User

@MJALARI Sample data and such would help greatly. Maybe this will assist:

To *Bleep* with RANKX! - Microsoft Power BI Community


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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