I want to fetch a result set with some data sorted by RecId.
But the records are in large number, so I have to specific a range in every request.
So I write my code like this:
Query query; QueryRun qrun; QueryBuildDataSource qbds; QueryBuildRange qbr; query= new Query(); qbds = query.addDataSource(tableId); qbr= qbds.addRange(fieldName2Id(tableId,"RecId")); qbr.value(">"+int642Str(from)); qbds.addSortField(fieldName2Id(tableId,"RecId")); qrun = new QueryRun(query);
But the result is confused. The range is right, but the result set is not sorted.
How to resolve it?
*This post is locked for comments