QuickView Grid Utility - Overview

In BBj 16.0 and higher, the "QuickView Grid" utility class is a BBj custom object that implements grid paging for SQL based queries. It handles the vertical scrolling through the result set and coordination with user actions to load at most the number of visible grid rows at any one time. This reduces the load that the grid has to manage, thus increasing display speed, especially for larger data sets. The main program makes the SQL (JDBC) connection and issues the SELECT command to generate the initial SQL ResultSet object that is then used to populate the new BASIS Components ResultSet (BCRS).

The BCRS is modelled closely after the Java SQL ResultSet, but is 0-based and does not require the connection to stay active. The developer has the choice of letting the result set metadata be automatically built from the SQL result set or setting the metadata specifically, including custom attributes picked up by the QuickView Grid using helper methods found in the BCRS class. The prepared BCRS object is registered with the QuickView Grid object.

The QuickView Grid uses a BBjStandardGrid and provides all non-editing related BBj grid methods, either handling the action itself or relaying it to the underlying BBj grid. There is a provision for certain "shared" actions, such as selecting a grid row, that is handled by the QuickView Grid first and then relayed as a "process event" to the main program. This allows the QuickView Grid to be used as an alternative to the BBjStandardGrid.

The QuickView Grid also offers a "RowListener" interface, that when implemented and registered with the QuickView Grid object, allows for the main program to interact when the data rows are being processed on their way to the grid. This can be used to set particular grid row and/or cell attributes based on the data, or whether the data row should be included in the grid at all. An accompanying test program under utils/qvgrid/qvgridtest.bbj, is the best source for a practical example of using the new class.



For complete QuickView Grid Utility documentation, click here.


The "QuickView Grid" loads and processes only the number of visible grid rows at any one time, significantly reducing the amount of data being transferred to the client. Grid data is displayed much more quickly, on an as-needed basis.