Not able to retrieve data from DB

Hi All,

I am running below query to get the data from a table which has 1000+ rows . But it gives me error "Expression evaluation error at function a!queryEntity: An error occurred while retrieving the data." .

When i query DB it doesn't take more than 20 ms . Any help on what can be done?

a!queryEntity(
entity: cons!XYZ,
query: a!query(
logicalExpression: a!queryLogicalExpression(
operator: "AND",
filters: {
a!queryFilter(
field: "helpId",
operator: "=",
value: 2
)
},
ignoreFiltersWithEmptyValues: true
),
pagingInfo: a!pagingInfo(
startIndex: 1,
batchSize: -1
)
),
fetchTotalCount: true
).data

Thanks in advance

  Discussion posts and replies are publicly visible

Parents
  • Hi Anu,

    Can you please try to to minimize the data that you are retriving by configuring the paginginfo as, (1,200) or something instaed of trying to fetch the entire set of records. If your idea is to display these data in a grid, then minimizing the data retrival through pagingInfo would definitely work.

  • I'd also suggest trying to narrow down the set of fields you are trying to return. For instance, use a query selection to only return certain columns. Then, you can find out if one of the columns cannot be queried and you can investigate that column further.

    I'd also suggest checking your data store. In the data store, try to validate and see if there are any errors when validating your CDTs against the current database structure.

Reply
  • I'd also suggest trying to narrow down the set of fields you are trying to return. For instance, use a query selection to only return certain columns. Then, you can find out if one of the columns cannot be queried and you can investigate that column further.

    I'd also suggest checking your data store. In the data store, try to validate and see if there are any errors when validating your CDTs against the current database structure.

Children
No Data