class BuiltinLookup(Lookup):
Known subclasses: django.db.models.lookups.Exact
, django.db.models.lookups.GreaterThan
, django.db.models.lookups.GreaterThanOrEqual
, django.db.models.lookups.IExact
, django.db.models.lookups.In
, django.db.models.lookups.IsNull
, django.db.models.lookups.LessThan
, django.db.models.lookups.LessThanOrEqual
, django.db.models.lookups.PatternLookup
, django.db.models.lookups.Range
, django.db.models.lookups.Regex
Undocumented
Method | as_sql |
Responsible for returning a (sql, [params]) tuple to be included in the current query. |
Method | get_rhs_op |
Undocumented |
Method | process_lhs |
Undocumented |
Inherited from Lookup
:
Method | __eq__ |
Undocumented |
Method | __hash__ |
Undocumented |
Method | __init__ |
Undocumented |
Method | __repr__ |
Undocumented |
Method | apply_bilateral_transforms |
Undocumented |
Method | as_oracle |
Undocumented |
Method | batch_process_rhs |
Undocumented |
Method | get_db_prep_lookup |
Undocumented |
Method | get_group_by_cols |
Undocumented |
Method | get_prep_lhs |
Undocumented |
Method | get_prep_lookup |
Undocumented |
Method | get_source_expressions |
Undocumented |
Method | process_rhs |
Undocumented |
Method | resolve_expression |
Provide the chance to do any preprocessing or validation before being added to the query. |
Method | rhs_is_direct_value |
Undocumented |
Method | select_format |
Custom format for select clauses. For example, EXISTS expressions need to be wrapped in CASE WHEN on Oracle. |
Method | set_source_expressions |
Undocumented |
Class Variable | can_use_none_as_rhs |
Undocumented |
Class Variable | lookup_name |
Undocumented |
Class Variable | prepare_rhs |
Undocumented |
Instance Variable | bilateral_transforms |
Undocumented |
Instance Variable | lhs |
Undocumented |
Instance Variable | rhs |
Undocumented |
Property | identity |
Undocumented |
Property | output_field |
Return the output type of this expressions. |
Inherited from BaseExpression
(via Lookup
, Expression
):
Static Method | _convert_value_noop |
Undocumented |
Method | __getstate__ |
Undocumented |
Method | _parse_expressions |
Undocumented |
Method | _resolve_output_field |
Attempt to infer the output type of the expression. If the output fields of all source fields match then, simply infer the same type here. This isn't always correct, but it makes sense most of the time. |
Method | asc |
Undocumented |
Method | copy |
Undocumented |
Method | desc |
Undocumented |
Method | flatten |
Recursively yield this expression and all subexpressions, in depth-first order. |
Method | get_db_converters |
Undocumented |
Method | get_lookup |
Undocumented |
Method | get_source_fields |
Return the underlying field types used by this aggregate. |
Method | get_transform |
Undocumented |
Method | relabeled_clone |
Undocumented |
Method | reverse_ordering |
Undocumented |
Class Variable | _output_field_resolved_to_none |
Undocumented |
Class Variable | filterable |
Undocumented |
Class Variable | is_summary |
Undocumented |
Class Variable | window_compatible |
Undocumented |
Property | _output_field_or_none |
Return the output field of this expression, or None if _resolve_output_field() didn't return an output type. |
Property | conditional |
Undocumented |
Property | contains_aggregate |
Undocumented |
Property | contains_column_references |
Undocumented |
Property | contains_over_clause |
Undocumented |
Property | convert_value |
Expressions provide their own converters because users have the option of manually specifying the output_field which may be a different type from the one the database returns. |
Property | field |
Undocumented |
Inherited from Combinable
(via Lookup
, Expression
):
Constant | ADD |
Undocumented |
Constant | BITAND |
Undocumented |
Constant | BITLEFTSHIFT |
Undocumented |
Constant | BITOR |
Undocumented |
Constant | BITRIGHTSHIFT |
Undocumented |
Constant | BITXOR |
Undocumented |
Constant | DIV |
Undocumented |
Constant | MOD |
Undocumented |
Constant | MUL |
Undocumented |
Constant | POW |
Undocumented |
Constant | SUB |
Undocumented |
Method | __add__ |
Undocumented |
Method | __and__ |
Undocumented |
Method | __mod__ |
Undocumented |
Method | __mul__ |
Undocumented |
Method | __neg__ |
Undocumented |
Method | __or__ |
Undocumented |
Method | __pow__ |
Undocumented |
Method | __radd__ |
Undocumented |
Method | __rand__ |
Undocumented |
Method | __rmod__ |
Undocumented |
Method | __rmul__ |
Undocumented |
Method | __ror__ |
Undocumented |
Method | __rpow__ |
Undocumented |
Method | __rsub__ |
Undocumented |
Method | __rtruediv__ |
Undocumented |
Method | __sub__ |
Undocumented |
Method | __truediv__ |
Undocumented |
Method | _combine |
Undocumented |
Method | bitand |
Undocumented |
Method | bitleftshift |
Undocumented |
Method | bitor |
Undocumented |
Method | bitrightshift |
Undocumented |
Method | bitxor |
Undocumented |
django.db.models.lookups.Exact
, django.db.models.lookups.In
, django.db.models.lookups.IsNull
, django.db.models.lookups.Regex
Responsible for returning a (sql, [params]) tuple to be included in the current query.
Different backends can provide their own implementation, by
providing an as_{vendor}
method and patching the Expression:
``` def override_as_sql(self, compiler, connection):
# custom logic return super().as_sql(compiler, connection)
setattr(Expression, 'as_' + connection.vendor, override_as_sql) ```
value
.sql
is a string containing ordered sql parameters to be
replaced with the elements of the list params
.django.db.models.lookups.In
, django.db.models.lookups.PatternLookup
, django.db.models.lookups.Range
Undocumented