RE: How to extract Invoice Related Records using transaction search.

Hi,

We are trying to extract the Invoice from Netsuite along with the related records. We are able to extract the Invoice and Lines without any issues but we  are not able to extract the Related Records of Invoice which has Credit Memo’s and Journal Entries. Below are the sample code we use.

TransactionSearch transactionsSearch = new TransactionSearch();
TransactionSearchBasic transactionSearchBasic = new TransactionSearchBasic();
transactionSearchBasic.type = new SearchEnumMultiSelectField();
transactionSearchBasic.type.@operator = SearchEnumMultiSelectFieldOperator.anyOf;
transactionSearchBasic.type.operatorSpecified = true;
transactionSearchBasic.type.searchValue = new string[] { “_invoice” };
ransactionsSearch.basic = transactionSearchBasic;
SearchPreferences sp = new SearchPreferences();
sp.pageSize = fetch_count;
sp.pageSizeSpecified = true;
sp.bodyFieldsOnly = false;
_service.searchPreferences = sp;
SearchResult result = _service.search(transactionsSearch);

It is a production issue so any help is highly appreicated.

Thanks and Regards

Venkatesan

venkateshmpr Rookie Asked on February 24, 2021 in SuiteTalk.
Add Comment
3 Answers

Is there anybody having idea on the above? Please let us know.

Thanks and Regards

Venkatesan

Rookie Answered on February 25, 2021.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.