There is no limit on `anyof` filters. I had this c...
# suitescript
e
There is no limit on
anyof
filters. I had this confirmed with NS, they tested with a million elements without an issue
👍🏼 2
s
Is there a limit on Formula with huge blocks of Case statements?
I haven’t run into any issues, but I’m curious.
e
that I am not sure about
d
@ehcanadian is there any limit if i use multiple OR operator?
z
Just for the information, I tried it for around 2K ids. It worked well. But for item id as text filters using 'OR' on around 1.5K ids took quite more time than normal search execution.
a
@ehcanadian Netsuite confirmed this with you? They said they tested 1 million? After hours of debugging, I found this is not true. Or at least if the
anyof
is on a joined field. I had this filter
Copy code
... ['customer.parent', 'anyof', parentIds], 'AND', ...
and I was breaking my head to figure out why it wasn't working. The netsuite error message is just an unexpected error has occurred. I broke the array with a length of about 1075 into 3 parts, and each one on its own worked. I then took the first 1001 results and it failed. I took the first 1000 results then it worked
c
ANYOF was restricted to 250 IDs as far as I can remember
a
@creece I suppose the workaround is to just expressions and keep using OR till I add all my needed filters
e
Thanks for waiting. The documentation for Filter objects doesn't explicitly indicate any limitations for the elements in an AnyOf operator, so there doesn't seem to be any. To test this, created an AnyOf filter with a million element values successfully in my test account.
I've used more than 10K
It wasn't a joined field though
c
must have updated a while back we couldn't get any more than 250 to work...maybe they SHOULD document it 😄