jQWidgets Forums

jQuery UI Widgets Forums Grid Paging and scrolling – under the hood

This topic contains 1 reply, has 2 voices, and was last updated by  svetoslav_borislavov 1 year, 8 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • Paging and scrolling – under the hood #133602

    kkovacs
    Participant

    Hi,
    I’m not sure how the scrolling and server-side paging actually works under the hood, but I have a feeling that both queries all the records for each user interaction (scrolling down in case of scrolling, going to next page in case of paging).
    We’ve got a query that returns a massive amount of records and I’d like to find an efficient solution to display that data in jqxGrid.
    Would you please tell how each approach works and renders the data on the screen and what’s the best practice in case of mass data?
    Is there a solution that queries the records once only and renders the data on-demand from that result without querying the whole over & over again?

    If I get it right, server-side pagination works in a way that every time the user clicks the next page, the whole query is evaluated, but returns only the next section of it, then it gets rendered on the screen. With this I’d like to have a solution that saves the query into the memory for the first run and when user goes to the next page, it rather renders the grid from that saved data. If possible, I’m afraid it’s not…
    Scrolling works in a way that for every scroll, the whole query runs each time and renders the next section. Neither this solution sounds efficient to me.

    In short: is there a solution which runs the query only once?

    Thanks in advance!
    Karoly

    Paging and scrolling – under the hood #133609

    Hi,

    In the following demo with the virtual paging, you may see that in the rendergridrows callback, the data is generated by passing the startindex and the endindex. This way, you can fetch only the required data.
    https://www.jqwidgets.com/jquery-widgets-demo/demos/jqxgrid/index.htm#demos/jqxgrid/virtualdata.htm

    Another option is to use our newer product, here is an example of Server-Side Pagination with our newer product:
    https://www.htmlelements.com/demos/grid/server-side-paging-sorting-filtering/

    Best regards,
    Svetoslav Borislavov

    jQWidgets Team
    https://www.jqwidgets.com/

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.