Lorenzo
02/14/2025, 11:30 AMCeligo AI
02/14/2025, 11:31 AMAI generated answer (using internal Slack threads):In order to get a full result set from a SuiteQL query through the REST endpoint, you can use the
offset
parameter. The offset
parameter is used to specify the starting point in the set of rows returned by your query. For example, if you have a query that returns 5000 rows, and you want to get rows 1001 to 2000, you would use offset=1000
.
Here is an example of how you can use the offset
parameter:
json
{
"q": "SELECT * FROM item ORDER BY itemId",
"limit": 1000,
"offset": 1000
}
In this example, the limit
parameter is used to specify the maximum number of rows to return, and the offset
parameter is used to specify the starting point in the set of rows returned by the query.
Please note that the offset
parameter is zero-based. This means that if you want to start from the first row, you would use offset=0
.
Also, keep in mind that the REST API has a limit of 1000 rows per request. If you want to retrieve more than 1000 rows, you will need to make multiple requests and increment the offset
parameter for each subsequent request.
For example, to retrieve the first 2000 rows, you would make two requests. The first request would have offset=0
and limit=1000
, and the second request would have offset=1000
and limit=1000
.
Finally, when using the offset
parameter, it's a good practice to include an ORDER BY
clause in your query to ensure that the rows are returned in a consistent order.
******
Disclaimer:
This response was generated by an artificial intelligence assistant based on previous conversations from multiple Slack channels, and may contain inaccuracies or mistakes.
******Celigo AI
02/14/2025, 11:31 AMSlack thread 1: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.804559648
Slack thread 2: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.803531587
Slack thread 3: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.79540211
Celigo AI
02/14/2025, 11:31 AM