Open rogalski opened 2 years ago
It's a trifle more complex than the docs say. Operators exist as functions in sqlalchemy.sql.operators
and as methods of sqlalchemy.sql.operators.ColumnOperators
, and the names aren't quite consistent. Some of the module-level functions end with _op
, and some don't.
Here's what I found out experimentally. First, module-level functions:
old name | new name |
---|---|
isfalse | is_false |
isnot_distinct_from | is_not_distinct_from |
istrue | is_true |
notbetween_op | not_between_op |
notcontains_op | not_contains_op |
notendswith_op | not_endswith_op |
notilike_op | not_ilike_op |
notlike_op | not_like_op |
notmatch_op | not_match_op |
notstartswith_op | not_startswith_op |
nullsfirst_op | nulls_first_op |
nullslast_op | nulls_last_op |
isnot | is_not |
notin_op | not_in_op |
And methods of class ColumnOperators:
old name | new name |
---|---|
isnot_distinct_from | is_not_distinct_from |
notilike | not_ilike |
notlike | not_like |
nullsfirst | nulls_first |
nullslast | nulls_last |
isnot | is_not |
notin_ | not_in |
PR coming shortly...
SQLAlchemy 1.4 release notes: https://docs.sqlalchemy.org/en/14/changelog/changelog_14.html#change-8dd50c1cc4d512bf97b23fb0243619af
Stubs needs to be updated:
Version: