Discussions
Multiple Searches
I am tring to do some code for item pricing. The code itself is not that important. One thing I have come accross multiple times and can't find an answer to, is when I run more than one search in code. For example:
var recType = 'invoice';
var histCol = [];
histCol[0]= new nlobjSearchColumn('entity');
histCol[1]= new nlobjSearchColumn('item');
histCol[2]= new nlobjSearchColumn('amount');
histCol[3]= new nlobjSearchColumn('rate');
histCol[4]= new nlobjSearchColumn('recordtype');
histCol[5]= new nlobjSearchColumn('trandate');
var histFilter = [];
histFilter[0]= new nlobjSearchFilter('entity', null, 'is', custid);
histFilter[1]= new nlobjSearchFilter('item', null, 'is', itemId);
histFilter[2]= new nlobjSearchFilter('recordtype', null, 'is', recType);
var histSearch = nlapiSearchRecord('transaction', null, histFilter, histCol);