web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / How to CountRows large...
Power Apps
Unanswered

How to CountRows large datasets (2000+)

(0) ShareShare
ReportReport
Posted on by 82

Hey, 

I want to count rows of a SQL-Table, but SQL is marked with a delegation warning.

I increased the data row limit for non-delegable queries to 2000 (max).

Unfortunately my table has more than 2000 records.

If I display the table as a gallery and count the rows of the gallery, I have to scroll to the bottom of the gallery.

 

Thanks for your help.

2019-10-08 10_27_39-QC365 - Saved (Unpublished) - PowerApps.png
2019-10-08 10_26_53-.png
Categories:
I have the same question (0)
  • timl Profile Picture
    37,252 Super User 2026 Season 1 on at

    Hi @JonasH 

    Unfortunately, it's not possible to retrieve an accurate record count from within PowerApps due to the 2000 row limit.

    If you want a straight count of the records in your table, one way to work around this is to use a SQL Server View.

    You can create a view in SQL Server that looks like this:

     

     

    CREATE VIEW vwTableCount
    AS
    SELECT COUNT(*) AS [RowCount]
    FROM
    dbo.MyTable

    In your app, you can add this View as a datasource. In the label where you want to display the count, you can use the following formula:

    First(vwTableCount).RowCount

     

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 339 Most Valuable Professional

#2
11manish Profile Picture

11manish 180

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 88 Super User 2026 Season 1

Last 30 days Overall leaderboard