Database Server Mode
- 2 minutes to read
If you need to connect a pivot grid control to a database with a large number of records, you can use server mode. Server mode has been specifically designed to work with large datasets. In this mode, the pivot grid control performs data-aware operations on the database server side. That ensures quick access to data, even if grouping and filtering are used.
For end-users, the pivot grid control functions identically in regular and server modes. In server mode, they can scroll the pivot grid, sort, group and filter data, and calculate summaries.
The Pivot Grid Control can perform data-aware operations (retrieving data from the server, grouping, filtering data and calculating summaries) in a background thread, allowing the entire application to stay responsive while these operations are in progress. To enable asynchronous mode, set the PivotGridOptionsBehaviorBase.UseAsyncMode property to true.
Server Mode Data Sources
The PivotGridControl automatically operates in server mode if it is bound to an appropriate data source. Use one of the following data sources to enable this mode.
|Data Access Technology||Server Mode Data Source|
|LINQ to SQL||LinqServerModeSource|
Server Mode Limitations
Server mode is not supported when the Pivot Grid uses the Optimized calculation because this engine calculates data on the client side.
In server mode, the pivot grid control doesn’t have simultaneous access to bound data in its entirety and this imposes certain limitations on the pivot grid’s features. See the list below for information on features that are not supported in server mode.
- Custom summaries calculated using the PivotGridControl.CustomSummary event.
- Custom grouping using the PivotGridControl.CustomGroupInterval event.
- Custom sorting using the PivotGridControl.CustomFieldSort event (in OLAP and server mode, use the PivotGridControl.CustomServerModeSort event instead).
- Providing data for unbound fields using the PivotGridControl.CustomUnboundFieldData event.
- Filtering by summary values
The following step-by-step tutorials demonstrate how to bind a Pivot Grid control to the server-mode data sources.