The expression builder has a whole section of functions for dealing with arrays.
array
Returns an array containing all the values passed as parameter
array_append
Returns an array with the given value added at the end
array_cat
Returns an array containing all the given arrays concatenated
array_contains
Returns true if an array contains the given value
array_distinct
Returns an array containing distinct values of the given array
array_filter
Returns an array with only the items for which an expression evaluates to true
array_find
Returns the index (0 for the first one) of a value within an array. Returns -1 if the value is not found.
array_first
Returns the first value of an array
array_foreach
Returns an array with the given expression evaluated on each item
array_get
Returns the Nth value (0 for the first one) of an array
array_insert
Returns an array with the given value added at the given position
array_intersect
Returns true if any element of array_1 exists in array_2
array_last
Returns the last element of an array
array_length
Returns the number of elements of an array
array_prepend
Returns an array with the given value added at the beginning
array_remove_all
Returns an array with all the entries of the given value removed
array_remove_at
Returns an array with the given index removed
array_reverse
Returns the given array with array values in reversed order
array_slice
Returns the values of the array from the start_pos argument up to and including the end_pos argument
array_to_string
Concatenates array elements into a string separated by
a delimiter and using optional string for empty values
generate_series
Creates an array containing a sequence of numbers
regexp_matches
Returns an array of all strings captured by capturing groups, in the order the groups themselves appear in the supplied regular expression against a string
string_to_array
Splits string into an array using supplied delimiter and optional string for empty values
(Source: QGIS User Manual)
Use array_contains(your_array, "field")
to test whether your array contains the current field value.
array_find(['value1','value2'], "field") <> -1
returns0
(True) if field in array.