VQL: not contains operator?

I'm trying to run a query to exclude documents whose type__v is in a list of values. However, this does not work:

select id from documents where type__v not contains('Type 1', 'Type 2', 'Type 3')

I then get Unknown token [not] found near position [54] at line [1]

How should express this? Do I need to do a series of != clauses (which is much less readable)?

1 comment

  • Avatar
    Mark Arnold Official comment

    Raphael, VQL does not support "not" in where clauses, so you will need to filter on "!=" for each type__v value:

    select id from documents where type__v != 'Type 1' and type__v != 'Type 2' and type__v != 'Type 3'

Please sign in to leave a comment.