(self, compiler, connection)
| 129 | ) |
| 130 | |
| 131 | def as_sql(self, compiler, connection): |
| 132 | if ( |
| 133 | not connection.features.supports_tuple_comparison_against_subquery |
| 134 | and isinstance(self.rhs, Query) |
| 135 | and self.rhs.subquery |
| 136 | and isinstance( |
| 137 | self, (GreaterThan, GreaterThanOrEqual, LessThan, LessThanOrEqual) |
| 138 | ) |
| 139 | ): |
| 140 | lookup = self.lookup_name |
| 141 | msg = ( |
| 142 | f'"{lookup}" cannot be used to target composite fields ' |
| 143 | "through subqueries on this backend" |
| 144 | ) |
| 145 | raise NotSupportedError(msg) |
| 146 | if not connection.features.supports_tuple_lookups: |
| 147 | return self.get_fallback_sql(compiler, connection) |
| 148 | return super().as_sql(compiler, connection) |
| 149 | |
| 150 | |
| 151 | class TupleExact(TupleLookupMixin, Exact): |
nothing calls this directly
no test coverage detected