4 | | 3. When generating the SQL for a queryset which isn't a subquery of another queryset, we check for existence of EMPTY_PARAM in the params generated for the where clause. If one is found, we know we don't need to execute the queryset at all. |
5 | | 4. In all other cases we run the query with the empty param. The condition is always going to fail in the generated SQL, but that is exactly what we want for this ticket. |
| 4 | 3. We check for EMPTY_PARAM in the params inside WhereNode and do necessary conversions for full/empty resultset cases when generating the SQL. |
| 5 | 4. When generating the SQL for a queryset which isn't a subquery of another queryset, we check for existence of EMPTY_PARAM in the params generated for the where clause. If one is found, we know we don't need to execute the queryset at all. |
| 6 | 5. In all other cases we run the query with the empty param. The condition is always going to fail in the generated SQL, but that is exactly what we want for this ticket. |