无法从Netsuite中的库存调整中获取自定义字段值

无法从Netsuite中的库存调整中获取自定义字段值,netsuite,Netsuite,我正在进行Ns集成,我已将一个自定义字段(例如:仓库名称)添加到InventoryAdjustment。并输入和保存了一些InventoryAdjustment记录。现在我正在尝试获取该自定义字段的值。在我的应用程序中使用Java的代码是…获取null请建议我如何获取自定义字段值 SearchResult res = _port.search(tsb); RecordList rl=res.getRecordList(); Record[] records=rl.

我正在进行Ns集成,我已将一个自定义字段(例如:仓库名称)添加到InventoryAdjustment。并输入和保存了一些InventoryAdjustment记录。现在我正在尝试获取该自定义字段的值。在我的应用程序中使用Java的代码是…获取null请建议我如何获取自定义字段值

SearchResult res = _port.search(tsb);
        RecordList rl=res.getRecordList();
        Record[] records=rl.getRecord();

        String salesord=null;

        String date=null;
        for(Record rcd:records){
            salesord=rcd.getClass().getName();
        if(rcd instanceof InventoryAdjustment){
            InventoryAdjustment inv=(InventoryAdjustment)rcd;

            CustomFieldList customFieldList=inv.getCustomFieldList();
                System.out.println(customFieldList);//getting null
                CustomFieldRef[] cfl=customFieldList.getCustomField();

                for(CustomFieldRef customFieldRef:cfl)
                {


System.out.println("........."+customFieldRef.getClass());
                    }

搜索不会返回所有字段/列表。您可以尝试在搜索结果中使用get()来获取完整的对象。search()返回对象的内部ID,然后可以在get()中使用该ID