class custom_op(object):
Represent a 'custom' operator.
.custom_op
is normally instantiated when the
.Operators.op
or .Operators.bool_op
methods
are used to create a custom operator callable. The class can also be
used directly when programmatically constructing expressions. E.g.
to represent the "factorial" operation:
from sqlalchemy.sql import UnaryExpression from sqlalchemy.sql import operators from sqlalchemy import Numeric unary = UnaryExpression(table.c.somecolumn, modifier=operators.custom_op("!"), type_=Numeric)
See Also
.Operators.op
.Operators.bool_op
Method | __call__ |
Undocumented |
Method | __eq__ |
Undocumented |
Method | __hash__ |
Undocumented |
Method | __init__ |
Undocumented |
Class Variable | __name__ |
Undocumented |
Instance Variable | eager_grouping |
Undocumented |
Instance Variable | is_comparison |
Undocumented |
Instance Variable | natural_self_precedent |
Undocumented |
Instance Variable | opstring |
Undocumented |
Instance Variable | precedence |
Undocumented |
Instance Variable | return_type |
Undocumented |