# NOT IN predicate transformations

NOT IN lists are transformed into multiple predicates that use the <> operator. <> predicates are not optimizable, but they are sargable (See Internal language transformations). For example:

    orig_airport NOT IN ('ABQ', 'AKL', 'DSM')

becomes

    orig_airport <> 'ABQ'
    AND orig_airport <> 'AKL'
    AND orig_airport <> 'DSM'

In addition, large lists are sorted in ascending order for performance reasons.

Parent topic: Predicate transformations
Related reference
BETWEEN transformations
LIKE transformations
Simple IN predicate transformations
OR transformations