Get row COUNT for saved report

I need to get a count of record of a saved report. Currently the only way I can do it is to guess the page number and with binary search come to the page I need, but that is too much of api requests and they are so easy to optimize. Besides I can get this number using dashboard widgets.
Is there a better way?

Hi @sdirin_Dirin, unfortunately there isn’t a way to return the count of a saved report.

Hi @sdirin_Dirin,

While that would be a valuable function to have, the api does not present any way to get saved search counts. Depending on how complicated the search is, there are basic searches you could use the dsCount method to determine but that would be very basic searches only.

Yes that is no help. To get my report with table I have to combine 3 big tables and that is gonna take more resources than guessing the last page on saved report. It is just causes too much of “request took too long and has been canceled” errors.

Yup, that would be the definition of NOT a simple query. Afraid there isn’t a way then.

Alternative idea here.

What type of report are you running here?

Some fo the Saved Search data would be available in the API Tables.
I am thinking that if the main data is accessible via an API Table you could run a dsCount on that table with near similar queries. Although depends on how complicated the report is.
Then it could give you an idea on how many pages their are.

The other alternative is to have the report come back in a particular sort order. You could then store the data in your own database, and reference i from there. But again, it depends on how complicated it is, and if sorting would help or not.

Hello. Sorting is a good idea. I need Compain Goals Completion report.

Have to dismiss my first suggestion as that data is not retrievable via the API Tables.

I would recommend storing the data in a database when you retrieve it.
Saves having to hit the API all the time.

Yes I thought about it and the idea of sorting data and save last inserted row seams ok.