You are currently reviewing an older revision of this page.
Users may experience one or more of the following symptoms:
When querying a database table or view from an expression rule, totalCount shows a different value than the actual number of results when:
totalCount
batchSize
fetchTotalCount
For Example:
When trying to use query results as data in an a!gridField component, the interface fails to load with an error similar to:
a!gridField
Additionally, the application server log shows and error similar to the following:
A grid component [label=“”] has an invalid value for “totalCount”. “totalCount” must not be null or less than the number of items in any of the “data” arrays, but “totalCount” was 0 and the largest column data array had 8 items. (APNX-1-4198-000)
There are two possible causes for this issue:
totalCount is determined based on the number of unique entries in the primary key field. If the primary key field contains duplicate, non-unique values or null values, totalCount will not match the actual number of result items.
This article applies to all versions of Appian.
Last Reviewed: May 2020