ugh, the SS2.0 search gets me every time with the ...
# suitescript
d
ugh, the SS2.0 search gets me every time with the
filters
vs
filterExpression
. the docs say there's a
filterExpression
property. But instead you pass your filter expression into the
filters
property.
Copy code
search.create({
  type: "my_custom_type",
  filters: [["customfield", "is", "ok"], "and", ["otherfield", "is", "finetoo"]]
But this will not work (well it will, it'll just return all your records)
Copy code
search.create({
  type: "my_custom_type",
  filterExpression: [["customfield", "isnot", "ok"], "and", ["otherfield", "is", "notfinetoo"]]