【问题标题】:NetSuite SuiteTalk SOAP API: Jump on Internalid when create new departmentNetSuite SuiteTalk SOAP API:创建新部门时跳转 Internalid
【发布时间】:2021-12-20 19:50:24
【问题描述】:

我正在使用 NetSuite SOAP API 从另一个应用程序创建新部门。 请求被正确处理并创建部门。 我的问题是新的 internalid 增量跳转到 100(例如:最后创建的部门 internalid 是 657,如果我使用 SOAP API 新创建的部门得到 id 757 而不是 658)。

我是否错过了正确的 +1 增量?

这里是 SOAP 请求的代码示例:

<SOAP-ENV:Body>
    <ns3:add>
        <ns3:record xsi:type="ns1:Department" externalId="80004">
            <ns1:name>80004 - my new Department</ns1:name>
            <ns1:parent/>
            <ns1:subsidiaryList>
                <ns2:recordRef internalId="1"/>
            </ns1:subsidiaryList>
            <ns1:customFieldList>
                <ns2:customField xsi:type="ns2:SelectCustomFieldRef" internalId="18">
                    <ns2:value typeId="4" internalId="7">
                        <ns2:name>Projet</ns2:name>
                    </ns2:value>
                </ns2:customField>
            </ns1:customFieldList>
        </ns3:record>
    </ns3:add>
</SOAP-ENV:Body>

【问题讨论】:

    标签: soap netsuite suitetalk


    【解决方案1】:

    您不能依赖内部 ID 是连续的。对于在同一脚本运行中创建的项目,它们有时会跳跃 100。

    我认为这与 Netsuite 不是事务性有关,但无论出于何种原因,它都是正常的。

    【讨论】:

    • 这不是事务性与非事务性的,但很简单地是 SQL(无论是 MS 还是 Oracle)中的一个事实,即 IDENTITY 不保证自动增量值,因为它取决于诸如服务器重启,其他活动等。底线,没什么好担心的。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-03-11
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2023-02-03
    相关资源
    最近更新 更多