JSDO and record counts

Posted by Darren Parr on 18-Oct-2019 10:54

Hi

We've implemented JFP business entities and it all works fine. There is an issue with server-side paging and record counts.some of our counts take a while and we're looking how to get around this.

For large datasets, we we would like a solution which works. The way I see it...

1. Put 999999 as a record count for large datasets. What happens on last page? Is this handled correctly?

2. Store record counts in the db for certain queries. Whilst this works to an extent, some reservations have been made about the accuracy of the data when they press the last page button.

3. Can the JSDO be told to ignore counts and change its interface to not allow for last page buttons etc. ie first, next, previous etc. It would be nice if a sign could show that the count of records was indeterminate.

I guess we'd like a solution where we can use server-side paging, sorting and filtering without big counts.

Any ideas?

Thanks

Darren

All Replies

Posted by egarcia on 18-Oct-2019 13:17

Quick reply:

You can create your own mappingType plugin or extend the JFP plugin to include the new logic.

In your mappingType plugin, you can the set "server.count" to specify the count.

In your code, you would not set the countFnName to avoid it being called as part of the request.

Related links:

- documentation.progress.com/.../index.html

- community.progress.com/.../58816

I hope this helps.

Posted by Mike Fechner on 18-Oct-2019 17:37

We've also implemented some logic around counting. We can cache the result of the count request and we never count for more then one second. We return a "magic number" as the count to indicate we don't know the count.

In those situations the Kendo UI grid is customized not to show the count.

The last page has never been a concern to us.

When the count is not present on the UI, we let the grid page next until the backend returns no further data.

Posted by Darren Parr on 23-Oct-2019 14:41

Sounds good Mike. Have you changed kendo/JSDO to do this? If not would you be willing to say what was needed to do it. I have a JS person who I could task with this if necessary.

This thread is closed