Skip to content

Commit e5a2a8b

Browse files
authored
Merge pull request tylertreat#143 from alireza-hosseini/feat-is-null-condition
feat: Support `IS NULL` and `IS NOT NULL` conditions
2 parents d308391 + 40de946 commit e5a2a8b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

bigquery/query_builder.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,8 @@ def _render_condition(field, field_type, comparators):
241241
else:
242242
value = _render_condition_value(value, field_type)
243243
value = "(" + value + ")"
244+
elif condition == "IS NULL" or condition == "IS NOT NULL":
245+
return field + " " + condition
244246
elif condition == "BETWEEN":
245247
if isinstance(value, (tuple, list, set)) and len(value) == 2:
246248
value = ' AND '.join(

0 commit comments

Comments
 (0)