Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Microsoft Dataverse
Answered

FetchXML: how to get records by page and records count in the same query?

Like (0) ShareShare
ReportReport
Posted on 26 Feb 2024 12:31:44 by 264

Hi, guys!

There are about 50k records in my entity.

I use "PA: List Rows" with some conditions to get records.

 

 

<fetch count='@{triggerBody()['number']}' page='@{triggerBody()['number_1']}' >
 <entity name='pbl_items'>
 <attribute name='pbl_itemsid' />
......

 

 

So I get a portion of records, but i'd like to get record count that match my conditions.

Is it possible to get RecordCount in the same query (in one touch)?

Maybe FetchXML has the feature/trick?

  • Max77 Profile Picture
    264 on 26 Feb 2024 at 20:14:53
    Re: FetchXML: how to get records by page and recors count in the same query?

    @a33ik thank you very much!

    It works.

    The list Rows result contains odata.count

    Max77_0-1708978423647.png

     

  • Verified answer
    a33ik Profile Picture
    3,304 Most Valuable Professional on 26 Feb 2024 at 19:20:28
    Re: FetchXML: how to get records by page and recors count in the same query?

    Hello,

    You can try to use the following attribute in FetchXml query:

    <fetch returntotalrecordcount="true">

     It should return the total number of records. One thing I'm not sure is how to get it out of the results.

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

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Leaderboard > Power Apps - Microsoft Dataverse

#1
mmbr1606 Profile Picture

mmbr1606 22 Super User 2025 Season 1

#2
stampcoin Profile Picture

stampcoin 17

#3
ankit_singhal Profile Picture

ankit_singhal 11 Super User 2025 Season 1

Overall leaderboard

Featured topics

Loading started