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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Anonymous
Not applicable

Problem counting the top 5 URLs more visited

Good afternoon,

 

I have a column with the different URLs in the following format: 

 

/productpage;

/page;

/page;

/start

/home;

/productpage;

/blog

/blog

/blog

/page;

/page2;

 

 

I want to create a graph/table whatever that shows me the top 5. In some cases, the cells are empty (i.e, no page).

 

I tried this, but it is not doing it properly (chatdaten is the name of the table, and Im Bereich is the name of the "Url". It is counting more URLs than I actually have, and when I apply the top N, it does not take into account the empty cells, so the total amount is lower than the actual one.

 

Count URL =

COUNTX(FILTER(ALL('stag_zit chat_daten'),[Im_Bereich]=EARLIER('stag_zit chat_daten'[Im_Bereich])),[Im_Bereich])

 

What am I doing wrong? How should I do? Thx,

 

1 ACCEPTED SOLUTION
v-yingjl
Community Support
Community Support

Hi @Anonymous ,

Based on your description, you can create this measure and set top 5 for the visual:

Count url =
COUNTX (
    FILTER (
        ALL ( 'Table' ),
        'Table'[url column]
            IN DISTINCT ( 'Table'[url column] )
                && 'Table'[url column] <> BLANK ()
    ),
    [url column]
)

count.png

Attached a sample file in the below, hopes to help you.

 

Best Regards,
Community Support Team _ Yingjie Li
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

1 REPLY 1
v-yingjl
Community Support
Community Support

Hi @Anonymous ,

Based on your description, you can create this measure and set top 5 for the visual:

Count url =
COUNTX (
    FILTER (
        ALL ( 'Table' ),
        'Table'[url column]
            IN DISTINCT ( 'Table'[url column] )
                && 'Table'[url column] <> BLANK ()
    ),
    [url column]
)

count.png

Attached a sample file in the below, hopes to help you.

 

Best Regards,
Community Support Team _ Yingjie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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

Users online (1,173)