当我尝试进行 TransactionSearchAdvanced(SalesOrder 搜索)时,它会返回具有相同值的重复记录。BodyFieldsOnly 设置为 true。我的代码有什么问题。代码如下
TransactionSearchAdvanced advanced = new TransactionSearchAdvanced();
TransactionSearch search = new TransactionSearch();
TransactionSearchBasic basic = new TransactionSearchBasic();
TransactionSearchRow tsRow = new TransactionSearchRow();
TransactionSearchRowBasic rowBasic = new TransactionSearchRowBasic();
basic.setType(new SearchEnumMultiSelectField(new String[] { "_salesOrder" }, SearchEnumMultiSelectFieldOperator.anyOf));
basic.setAccount(new SearchMultiSelectField(new RecordRef[] { new RecordRef(null, "54", null, null) }, SearchMultiSelectFieldOperator.anyOf));
basic.setRecordType(new SearchStringField(RecordType._salesOrder , SearchStringFieldOperator.is));
basic.setOtherRefNum(new SearchTextNumberField(null, null, SearchTextNumberFieldOperator.notEmpty));
basic.setInternalIdNumber(new SearchLongField(lastProcessedPoSalesOrderInternalId, null, SearchLongFieldOperator.greaterThan));
search.setBasic(basic);
rowBasic.setOtherRefNum(new SearchColumnTextNumberField[]{new SearchColumnTextNumberField()});
rowBasic.setInternalId(new SearchColumnSelectField[]{new SearchColumnSelectField()});
tsRow.setBasic(rowBasic);
advanced.setColumns(tsRow);
advanced.setCriteria(search);
result = netsuiteService.searchBodyFields(advanced);