Question
Convert queryEntity into batches/Looping
I have below code. Can someone help how to break it into batches/looping in dynamic way. Its reaching threshold so i need to convert into batches/looping.
a!queryEntity(
entity: cons!MA_DSE_ABC,
query: a!query(
logicalExpression: a!queryLogicalExpression(
operator: "AND",
filters: {
a!queryFilter(
field: "Name",
operator: "=",
value: ri!name,
applyWhen: not(isnull(ri!name))
),
a!queryFilter(
field: "Id",
operator: "=",
value: ri!id,
applyWhen: not(isnull(ri!id))
),
}
),
pagingInfo: a!pagingInfo(startIndex: 1, batchSize: 2000)
),
fetchTotalCount: true()
),