DAX Fridays Battle

Sdílet
Vložit
  • čas přidán 5. 07. 2024
  • You have asked me many times to explain the difference between RANKX and TOPN and it is finally here.
    Links to related videos:
    00:30 Calculate vs calculatetable
    • DAX Fridays #186: CALC...
    01:55 Scalar vs table vs other DAX functions
    • #6 DAX Fridays! 101: S...
    05:56 Rankx function
    • DAX Fridays! #9: RANKX...
    Here you can download all the pbix files: curbal.com/donwload-center
    SUBSCRIBE to learn more about Power and Excel BI!
    / @curbalen
    Our PLAYLISTS:
    - Join our DAX Fridays! Series: goo.gl/FtUWUX
    - Power BI dashboards for beginners: goo.gl/9YzyDP
    - Power BI Tips & Tricks: goo.gl/H6kUbP
    - Power Bi and Google Analytics: goo.gl/ZNsY8l
    ☼☼☼☼☼☼☼☼☼☼
    POWER BI COURSES:
    Want to learn Power BI? How about you take one of our courses? Here you can find the available courses:
    curbal.com/courses-overview
    ☼☼☼☼☼☼☼☼☼☼
    ABOUT CURBAL:
    Website: www.curbal.com
    Contact us: www.curbal.com/contact
    ▼▼▼▼▼▼▼▼▼▼
    If you feel that any of the videos, downloads, blog posts that I have created have been useful to you and you want to help me keep on going, here you can do a small donation to support my work and keep the channel running:
    curbal.com/product/sponsor-me
    Many thanks in advance!
    ▲▲▲▲▲▲▲▲▲▲
    ************
    ************
    QUESTIONS? COMMENTS? SUGGESTIONS? You’ll find me here:
    Linkedin ► goo.gl/3VW6Ky
    Twitter ► @curbalen, @ruthpozuelo
    Facebook ► goo.gl/bME2sB
    #CURBAL #SUBSCRIBE

Komentáře • 76

  • @nikhargesumit9069
    @nikhargesumit9069 Před 3 lety

    Thanks Ruth.. Really appreciate for your efforts to provide such information to audience. I am big fan of yours. 😊

  • @pilarbaldominos2505
    @pilarbaldominos2505 Před 3 lety +1

    Thanks Ruth, you do not know how much you are helping me! Every Friday I am waiting for your Friday Dax video to learn something new and fun!

  • @CarlosEliezerHernandezPintor

    Very pedagogical as always Ruth, thanks...

  • @Travel_and_music_shorts
    @Travel_and_music_shorts Před 3 měsíci

    Awesome that was super clear and helpful.
    Have a great day :)

  • @dannyhometown
    @dannyhometown Před 3 lety

    Happy Friday Ruth, pretty clear explanation. :P

  • @parthmandal2647
    @parthmandal2647 Před rokem

    You really explained it so beautifully! Thanks a lot!

  • @raviranjansingh5527
    @raviranjansingh5527 Před 3 lety

    Thanks ,making a great video for us .this topic had before confision ,now is good.

    • @CurbalEN
      @CurbalEN  Před 3 lety

      Then I did my job right. Happy Friday!

  • @kahhengyeong7947
    @kahhengyeong7947 Před 3 lety

    Once again, clear cut explanation and it helps a lot compared to reading from Dax guide :)

    • @CurbalEN
      @CurbalEN  Před 3 lety +1

      Thanks for the feedback and happy Friday?

  • @PianoandCoffee
    @PianoandCoffee Před měsícem

    Love the way you explained these concepts. I’m preparing for the PL300. Liked and subbed.

    • @CurbalEN
      @CurbalEN  Před měsícem

      Welcome and good luck!

    • @PianoandCoffee
      @PianoandCoffee Před měsícem

      @@CurbalEN Quick update! I passed the exam this morning!!! 😃 Hope to keep consuming your content to learn from it!

    • @CurbalEN
      @CurbalEN  Před měsícem

      @PianoandCoffee Congrats!!! 🥳🥳🥳

  • @gospelmoto2833
    @gospelmoto2833 Před 7 měsíci

    Very clear to me. Many thanks!

  • @nikolaybarsukov4339
    @nikolaybarsukov4339 Před 3 lety

    Hi Ruth. Good explanation. Thank you!

  • @saseendrareddy1393
    @saseendrareddy1393 Před 3 lety

    Thanks ®u|-# i learnt all dax functions from your channel your doing great work 👍

  • @Unbox747
    @Unbox747 Před 3 lety

    Thank you! Very easy to understand!

  • @oyewoleismail2427
    @oyewoleismail2427 Před 2 lety

    Thanks for the video, it's just saved me.

  • @abhishekstatus_7
    @abhishekstatus_7 Před 3 lety

    Thanks for sharing this knowledge Ruth !! I recently came across a situation where a data set is having 0 values for few of the rows and I used RANKX function to helped me to get the top 5 and bottom 5 because the requirement was to see those numbers from ranking 1-5 for top and as well bottom 1-5. I used the visual level filter for top 5 and it was really working fine but when i do visual level filter for the bottom 5 it was only returning the zeroes in the visualization and customer don't wanted to see zeroes. Can you please elaborate more on the BOTTOM calculation or what is the best approach apart from visual level filter where we have null values or 0 values in the dataset !! Thanks again!!

  • @laviniaionescu8378
    @laviniaionescu8378 Před 2 lety

    Thank you for the video Ruth! quick question: why do we use all with RANKX but not with TOPN?

  • @Victor-ol1lo
    @Victor-ol1lo Před 3 lety

    Well explained Ruth! TOPN+SUMMERIZE+ITERATOR ....one of the strongest combos in DAX I know. Have a nice weekend!

    • @CurbalEN
      @CurbalEN  Před 3 lety

      Same to you Victor! Happy Friday:)

    • @jonimatix
      @jonimatix Před 3 lety

      Can you give an example of TOPN+SUMMERIZE+ITERATOR ? Really interested to know!

    • @Victor-ol1lo
      @Victor-ol1lo Před 3 lety +2

      @@jonimatix The basic idea is to use a table function like FILTER / CALCULATETABLE / SUMMARIZE etc. to filter the data source and to compute the required the value with an iterator like SUMX / MAXX / COUNTX etc.

  • @pratikfutane8131
    @pratikfutane8131 Před 4 měsíci

    Awesome!!

  • @fabianafsousa
    @fabianafsousa Před rokem

    You are awesome!!

  • @sriram3196
    @sriram3196 Před 11 měsíci

    Thanks Ruth, Cleared my confusion

  • @SuperAzizx
    @SuperAzizx Před 3 lety

    Thks for video enjoy ur weekend

  • @benoymammenmathew825
    @benoymammenmathew825 Před 10 měsíci

    Hi Great video, do you know of anyway i can use a table created inside a measure , in a table visual

  • @madiakns
    @madiakns Před 3 lety

    Nice video... but what if I want to show a range Eg Top 11-40 clients?

  • @entstuff381
    @entstuff381 Před 3 lety

    Thanks Ruth

    • @CurbalEN
      @CurbalEN  Před 3 lety +1

      You welcome and happy friday!

  • @Leopar525
    @Leopar525 Před 3 lety

    You are the best

  • @udusegbe
    @udusegbe Před 3 lety

    Hi Ruth - another clarity on difference between scalar & table functions! Reminds me of the song, "I Can See Clearly Now" (original by Johnny Nash) :-)
    Question though. At the 6:53 mark, the RANKX measure result showed sales ranked accordingly. However, I would have expected sales of same values to be ranked equally. For example, I would have expected ranks 1 & 2 to be 1 & 1 and then 3, etc. Actually, the only ranking that I saw clearly was rank 12. In other cases, like sales figure 10.540 - first 2 ranked the same but the 3rd instanced ranked 5! Could it be a case rounding in the background of the calculation? Just curious. Otherwise, I see clearly now when to use each (confused me many times)

    • @KiranKumar-hk5ji
      @KiranKumar-hk5ji Před 2 lety

      That is possible if you use Dense as an argument in Rankx Function

  • @visuss1
    @visuss1 Před rokem

    I have topn returning last two rows of a existing table with four columns, into a Variable, how would i refer individual colimn in that topn variable

  • @walidkhlil2872
    @walidkhlil2872 Před 3 lety

    thanks 🙏

  • @geoffrichardson7013
    @geoffrichardson7013 Před 3 lety

    Hi Ruth, thanks as always for this video. I have a question about RankX which is killing me! If the measure that I want to rank is itself calculated across multiple tables (using USERELATIONSHIP), what would I set in the first parameter of RANKX? Do I need to do a manual join on the various tables and then summarize it? I can't seem to understand the syntax that I need :-(

    • @CurbalEN
      @CurbalEN  Před 3 lety +1

      Sounds like a good question for the power bi community. Make sure to give details , as how your model is laid out to get correct answers!

  • @mohanravi3532
    @mohanravi3532 Před rokem

    Hi Ruth! In a scenario, a product and category both are in same table. And I want to filter product by each category separately. i.e. products split into two slicers named bikes products and components products. When I filter each product, it should add to crosstab. Can you please help me how to achieve this?

  • @thomasivarsson2468
    @thomasivarsson2468 Před 3 lety

    Kristallklart efter att ha sett din video.

  • @lso4jw251
    @lso4jw251 Před 11 měsíci

    I have do I get the rankings to not re-rank during drill through from District to a Franchise?

  • @Alireza-ih5vu
    @Alireza-ih5vu Před 2 lety

    perfect

  • @MrSpiritUAll
    @MrSpiritUAll Před 3 lety

    Nice! See you monday👍🥂

    • @CurbalEN
      @CurbalEN  Před 3 lety +1

      Another battle planned for Monday;)

  • @revenge9431
    @revenge9431 Před 3 lety +1

    How do you rank clients based on a measure not a calculated column?

  • @nacimamoufek1664
    @nacimamoufek1664 Před 3 lety

    very clear Thanks a lot :)

  • @arnav2399
    @arnav2399 Před 3 lety

    Please help me analysis service power bi, how to refresh data automatic

  • @sau002
    @sau002 Před 3 lety

    Good. But, I cannot see what you are dragging from. That is when I am lost. (around 6:45, when you are talking about RANK)

  • @MrDiogone
    @MrDiogone Před 3 lety

    Hi,
    i've tried that, and that works for unique id's...
    if instead of having an order id, you have a sales person name with multiple sales amounts, and you want to see what is his rank (of total sales), against the other sales people.. what needs to be changed in the code?
    i've tried the below, but it did not gave the correct output
    sales person rank =
    RANKX(
    ALLSELECTED([Sales person name]),
    CALCULATE(sum([Sales]))
    ,,ASC
    )
    and instead of having 1 to n output, i got 1, 1, 2, 3, 1...
    Could you help?
    much appreciated!
    Diogo

  • @ivanrybalchenko7225
    @ivanrybalchenko7225 Před 9 měsíci

    How to get TOPN orders with ties, 10 orders with different amounts (e.g. in your resul you only have top 6 not top 10 orders in fact)?

  • @juansantamaria1982g
    @juansantamaria1982g Před 3 lety

    Hello Ruth! Nice video. I have a problem to solve and i dont know an easy way with DAX: I have a date field, a product category, product and sales, how can i obtain the top 10 or 20 or X from the sales but from each category? For example, from march third 2020, these are the top 10 product sales in the cleaning products...

    • @CurbalEN
      @CurbalEN  Před 3 lety

      Have you tried asking in the power bi community?

  • @marounsader318
    @marounsader318 Před 3 lety

    hi ruth thanks for the video!
    now related vs relatedtable please ? :)

  • @venkatareddykummitha5863

    Give me the perfect data source set (which is useful for all your DAX videos). I saw the video getting the NorthWind data set but, I couldn't understand the ETL operations on it, and also it differs from other Dax videos data like columns in each table.
    So, Please guide me

  • @giri41
    @giri41 Před 3 lety

    Ruth, in my rankx tables rank is duplicated.. can you please help

  • @rifatxahir
    @rifatxahir Před 2 lety

    I have a survey where we asked in the rank of same products as 5 questions -
    Rank 1 - A/B/C/D
    Rank 2 - A/B/C/D
    Rank 3 - A/B/C/D
    Rank 4 - A/B/C/D
    Any easy way to calculate these options A,B,C,D on the basis of rank weight?

  • @williamarthur4801
    @williamarthur4801 Před 2 lety

    Has anyone tried using TOPN to return an Nth value, for example 3rd highest,
    TOPN( 3, Table, Table [ Sales] ) , then wrap in in MIN ( TOPN( 3, Table, Table [ Sales] ),[Sales]) this doesn't seem to work, but I feel it should. Any suggestions?

  • @basireddy1387
    @basireddy1387 Před 2 lety

    How about topn/ bottom n customers excluding 0 sale value

  • @venkatareddykummitha5863

    how to get bottom 10 ranks sales

  • @Phoenixspin
    @Phoenixspin Před 3 lety

    Ruth looks very intimidating in the thumbnail. She got my attention.

    • @CurbalEN
      @CurbalEN  Před 3 lety

      😂
      I will change it for a friendlier face next time!