Xdcr - how to filter by list of id

For filtering by id=1
this is working:

I need to implement filtering by thousands of specific ids.
something like:
'REGEXP_CONTAINS(META().id , [“1”,“222”,“444” …])

Another example of use ,
lets say i want to filter by specific field AND by list of possible Customer_IDs

REGEXP_CONTAINS(xattrs.CONV_RUN_NO,"Y") AND Customer_ID in [1,2,3]

This even dont pass the api validaiton(error 400)

Any idea?

@BgOKcomp , try : REGEXP_CONTAINS(META().id , “1 | 222 | 444”)

@pavithra.mahamani , thanks !
Using “|” as OR working :slight_smile:

Strange behavior in the xdcr for string type .
below n1sql working perfectly:
SELECT raw meta().id from party.organizationsearch WHERE REGEXP_CONTAINS(meta().id,“Organization_101394248184481173|Organization_325048616475917994”)

Or even this acceptable when running as query:

When i implement same on xdcr :

It seems that when comparing REGEXP_CONTAINS(key ,val)
the xdcr see un quoted key as integer ,or quoted key as string .
so it expect the value return as integer for un quoted key.
I tried to wrap the meta.id with TOSTRING() .
it not accepted .

It looks like bug or least (annoying ) limitation ,
as if from one hand xdcr interpret un quoted key as int from the other hand it wont let using any TO<STRING/NUMBER> .

1.Do u see any workaround for using meta().id "?
2.Case no WA , do u see anyother approach which will be easily implement to uniquely identify a document ?

@BgOKcomp , “|” only works with int or float types. This works for me:
REGEXP_CONTAINS(META().id, “^Organization_(?=101394248184481173|325048616475917994)”)

Also note that META().id is case sensitive.