Hey Guys, I want to pass OR condition in one filte...
# suitescript
a
Hey Guys, I want to pass OR condition in one filter, below is the code I am trying var columns = new nlobjSearchColumn('id'); var filters = new nlobjSearchFilter([['shortname',null,'is','Arizona'],'OR',['fullname',null,'is','Arizona']]); var totalRecords = nlapiSearchRecord(null,'customsearch476',filters,columns); How can I do this?
b
a
@battk Below is the code var columns = new nlobjSearchColumn('id'); var totalRecords = nlapiSearchRecord(null,'customsearch476',[['shortname',null,'equalTo','Arizona'],'or',['fullname',null,'equalTo','Arizona']],columns); Can you please let me know what I am doing wrong?
b
not sure what you are searching, but you should probably be using
is
to search text filters
not
equalto
a
Thanks @battk, I got the result. Thank You