NetSuite REST API 调用是否有已知的偏移量限制?

Is there a known offset limit for NetSuite REST API calls?

世界!我们正在尝试使用 NetSuite SuiteQL REST API 来下拉数据。对于我们正在采购的大多数记录,它工作得很好,但是当我们访问大型表时,我们遇到了一个有趣的障碍。

由于单页数据的已知限制是 1,000 行,我们只是以 1,000 的限制调用它,并以 1,000 行的增量设置偏移量。当我们为大于 100,000 行的记录偏移 100,000 行时,会发生一些有趣的事情。

如果我们调用 https://myinstance.suitetalk.api.netsuite.com/services/rest/query/v1/suiteql?limit=1000&offset=98000,我们将获得我们期望的所有链接。

{
"links": [
    {
        "rel": "previous",
        "href": "https://myinstance.suitetalk.api.netsuite.com/services/rest/query/v1/suiteql?limit=1000&offset=97000"
    },
    {
        "rel": "first",
        "href": "https://myinstance.suitetalk.api.netsuite.com/services/rest/query/v1/suiteql?limit=1000&offset=0"
    },
    {
        "rel": "next",
        "href": "https://myinstance.suitetalk.api.netsuite.com/services/rest/query/v1/suiteql?limit=1000&offset=99000"
    },
    {
        "rel": "last",
        "href": "https://myinstance.suitetalk.api.netsuite.com/services/rest/query/v1/suiteql?limit=1000&offset=753000"
    },
    {
        "rel": "self",
        "href": "https://myinstance.suitetalk.api.netsuite.com/services/rest/query/v1/suiteql?limit=1000&offset=98000"
    }
],
"count": 1000,
"hasMore": true,
"items": [
    {
        [heres my data]...

将其设置为 99,000,很多信息都会消失。它几乎以为这是最后一页了。

{
"links": [
    {
        "rel": "previous",
        "href": "https://myinstance.suitetalk.api.netsuite.com/services/rest/query/v1/suiteql?limit=1000&offset=98000"
    },
    {
        "rel": "first",
        "href": "https://myinstance.suitetalk.api.netsuite.com/services/rest/query/v1/suiteql?limit=1000&offset=0"
    },
    {
        "rel": "self",
        "href": "https://myinstance.suitetalk.api.netsuite.com/services/rest/query/v1/suiteql?limit=1000&offset=99000"
    }
],
"count": 1000,
"hasMore": false,
"items": [
    {
        [heres my data]...

将它设置为 100,000 flat out 给我一个错误。

{
"type": "https://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.5",
"title": "Not Found",
"status": 404,
"o:errorDetails": [
    {
        "detail": "The specified query parameter 'offset' is out of bounds. Provide value between 0 and 753000.",
        "o:errorQueryParam": "offset",
        "o:errorCode": "INVALID_PARAMETER"
    }
]

有没有人见过这种行为?我搜索了文档,找不到任何关于页面偏移量限制的提及,所以我认为这可能是某种错误(事实上它甚至告诉你最大界限并且它明显高于指定的偏移量使得我认为这是一个错误),但希望有人可能以前见过这个,更好的是,知道如何解决这个问题!

NetSuite REST Web 服务的官方文档提到了这个限制 [1]:

Using SuiteQL queries, you can return a maximum of 100,000 results. For more information, see query.runSuiteQLPaged(options).