ALL & ANY array expressions

<> ALL & = ANY array expressions

Description

An expression used to evaluate and compare each element of an array against a specified expression. (PostgreSQL Language Reference ANY & ALL (array))

Grammar Syntax

expression operator ANY (array expression)
expression operator ALL (array expression)

To support this expression SnowConvert translates the <> ALL to NOT IN and the = ANY to IN

Sample Source Patterns

Input Code:

IN -> PostgreSQL_01.sql
SELECT some_column <> ALL (ARRAY[1, 2, 3]) 
FROM some_table;

SELECT *
FROM someTable
WHERE column_name = ANY (ARRAY[1, 2, 3]);

Output Code:

OUT -> PostgreSQL_01.sql
SELECT some_column NOT IN (1, 2, 3)
FROM some_table;

SELECT *
 FROM someTable
 WHERE column_name IN (1, 2, 3);

Known Issues

There are no known issues

There are no related EWIs.

Last updated