Ignition Perspective table Virtualized and Pager explanations

Hello guys, Ignition 8.1.45 Perspective

I want to know the differences in fact of performance and behavior in a Perspective table when using properties "Virtualized" and "Pager".
I need to display tables with a large dataset retrieved from a SQL Select query, but optimizing and not load all data in the same time.

I understood Virtualized works as "load more rows when scroll", but if I ask the query to retrieve all rows from Database, the workload on the it will be high, correct?
Using the pager also will only limit the number of rows displayed on the screen but the load on the database will be high too.

I thought to implement a logic to make Select query with "OFFSET" based on current pager page, but I can't see a way to create the number of total pages (seems that it is automatically generated based on the total rows of the table data property) and need to re-execute the query with new OFFSET value changing the page.

Also, virtualized and pager can work together or one exclude the other if we display only for example 10rows/page and all are displayed without scroll?

I don't know if this is the best approach, what do you do in these situations?

The table's pager functionality works with the data loaded. Load all of your data to use the built-in pager.

Otherwise, you must disable the table's pager and make your own paging control components outside the table.

1 Like

Hello @pturmel
In your experience, is the pager enough even with large datasets?
Is there a more efficient method? Like fetch only a portion of rows from the database and only display them or something else?

The pager works fine with some thousands of rows, when virtualization is on. The virtualization control simply prevents the workload at the browser to produce the imagery of each row, with those rows formatting and perhaps nested views.

I would not try to make my own pager until I knew for sure I needed it.

1 Like