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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
nckpedersen
Helper I
Helper I

nth Instance in Power Query to count pageviews by session

I am trying to extrapolite user site flow using a pageview report that has unique session id, visit date/time, url, and referrer url. 

 

I'd like to sort by chronological (ascending) on the date column, then duplicate the table, remove all columns but session id, remove duplicates, assign an index value. Then merge that table with original, sort by index value, then count instance of that index value. 

 

I need a formula like =countif(A$1:A1)

 

nckpedersen_0-1659724451517.png

 

3 REPLIES 3
OliT
Resolver I
Resolver I

Hi @nckpedersen 

>> I'd like to sort by chronological (ascending) on the date column, then duplicate the table, remove all columns but session id, remove duplicates, assign an index value. Then merge that table with original, sort by index value, then count instance of that index value. 

So where are you stuck now? What do you need us to help you with?  If possible, please share a sample process diagram and your sample data.

 

 

Regards,

OliT

Ashish_Mathur
Super User
Super User

Hi,

Imke's solution here will answer your question - Solved: Custom column Index or Ranking by other column.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
lbendlin
Super User
Super User

Please provide sanitized sample data that fully covers your issue. I cannot help you without usable sample data.
Please paste the data into a table in your post or use one of the file services like OneDrive or Google Drive. I cannot use screenshots of your source data.

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.

Top Solution Authors