Skip to main content
October 10, 2023
Question

Expression evaluation error at function a!queryEntity: An error occurred while retrieving the data

  • October 10, 2023
  • 7 replies
  • 0 views

Hi

my query is working fine for the last 9 months and now it is showing errors as below:

Expression evaluation error at function a!queryEntity: An error occurred while retrieving the data. Details: Unexpected error executing query (type: [DetailViewDT3872], query: [queryentity expression], order by: [[Sort[AccNumber asc]]], filters:[null]) 

I built a new constant and it still did not work.

Could you please assist why it is starting to show this error and how to fix it?

this is my query:

a!queryEntity(

entity: cons!Detail_View,

query: a!query(

selection: a!querySelection(
columns: {a!queryColumn(field: "AccNumber")}
),

pagingInfo: a!pagingInfo(
startIndex: 1,
batchSize: -1
)

),

fetchTotalCount: true

).totalCount

7 replies

stefanhelzle0001
Brainy
October 10, 2023

That's probably a timeout. It seems like you just need the total count of items. Is there a specific reason why set the batch size to -1 and return a large number of rows?

Does this query hit a view? If yes, is this view performance tuned?

kend0001Author
October 10, 2023

yes it hit a view. and it has only 94 items, a small data set. I saw the view perfectly in Database. it was working fine before.

stefanhelzle0001
Brainy
October 10, 2023

Yeah, that's the typical problem with views. They work great for just a few rows, and break with more data.

But, 94 is not that much. How long does it take in database and how many rows are in the source tables?