class _MatchType(sqltypes.Float, sqltypes.MatchType): (source)
Undocumented
Method | __init__ |
Construct a Float. |
Inherited from Float
:
Method | result |
Return a conversion function for processing result row values. |
Class Variable | __visit |
Undocumented |
Class Variable | scale |
Undocumented |
Instance Variable | asdecimal |
Undocumented |
Instance Variable | decimal |
Undocumented |
Instance Variable | precision |
Undocumented |
Inherited from Numeric
(via Float
):
Method | bind |
Return a conversion function for processing bind values. |
Method | get |
Return the corresponding type object from the underlying DB-API, if any. |
Method | literal |
Return a conversion function for processing literal values that are to be rendered directly without using binds. |
Property | python |
Return the Python type object expected to be returned by instances of this type, if known. |
Class Variable | _default |
Undocumented |
Property | _effective |
Undocumented |
Property | _expression |
Undocumented |
Property | _type |
Return a rudimental 'affinity' value expressing the general class of type. |
Inherited from HasExpressionLookup
(via Float
, Numeric
):
Class |
|
Undocumented |
Inherited from Boolean
(via Float
, Numeric
, HasExpressionLookup
, MatchType
):
Class Variable | native |
Undocumented |
Instance Variable | create |
Undocumented |
Instance Variable | dispatch |
Undocumented |
Instance Variable | name |
Undocumented |
Method | _set |
Undocumented |
Method | _should |
Undocumented |
Method | _strict |
Undocumented |
Class Variable | _strict |
Undocumented |
Instance Variable | _create |
Undocumented |
Inherited from SchemaType
(via Float
, Numeric
, HasExpressionLookup
, MatchType
, Boolean
):
Method | adapt |
Undocumented |
Method | copy |
Undocumented |
Method | create |
Issue CREATE DDL for this type, if applicable. |
Method | drop |
Issue DROP DDL for this type, if applicable. |
Instance Variable | inherit |
Undocumented |
Instance Variable | metadata |
Undocumented |
Instance Variable | schema |
Undocumented |
Method | _is |
Undocumented |
Method | _on |
Undocumented |
Method | _on |
Undocumented |
Method | _on |
Undocumented |
Method | _on |
Undocumented |
Method | _set |
Associate with this SchemaEvent's parent object. |
Method | _variant |
Undocumented |
Class Variable | _use |
Undocumented |
Inherited from SchemaEventTarget
(via Float
, Numeric
, HasExpressionLookup
, MatchType
, Boolean
, SchemaType
):
Method | _set |
Undocumented |
Inherited from EventTarget
(via Float
, Numeric
, HasExpressionLookup
, MatchType
, Boolean
, SchemaType
, SchemaEventTarget
):
Class Variable | __slots__ |
Undocumented |
Inherited from Emulated
(via Float
, Numeric
, HasExpressionLookup
, MatchType
, Boolean
, SchemaType
, SchemaEventTarget
, EventTarget
):
Method | adapt |
Given an impl class, adapt this type to the impl assuming "emulated". |
Inherited from TypeEngineMixin
(via Float
, Numeric
, HasExpressionLookup
, MatchType
, Boolean
, SchemaType
, SchemaEventTarget
, EventTarget
, Emulated
):
Method | dialect |
Undocumented |
Property | _static |
Undocumented |
Inherited from TypeEngine
(via Float
, Numeric
, HasExpressionLookup
, MatchType
, Boolean
, SchemaType
, SchemaEventTarget
, EventTarget
, Emulated
, TypeEngineMixin
):
Method | __repr__ |
Undocumented |
Method | __str__ |
Undocumented |
Method | as |
Return an instance of the generic type corresponding to this type using heuristic rule. The method may be overridden if this heuristic rule is not sufficient. |
Method | bind |
Given a bind value (i.e. a :class:`.BindParameter` instance), return a SQL expression in its place. |
Method | coerce |
Suggest a type for a 'coerced' Python value in an expression. |
Method | column |
Given a SELECT column expression, return a wrapping SQL expression. |
Method | compare |
Compare this type against the given backend type. |
Method | compare |
Compare two values for equality. |
Method | compile |
Produce a string-compiled form of this :class:`.TypeEngine`. |
Method | copy |
Undocumented |
Method | evaluates |
Return a copy of this type which has the :attr:`.should_evaluate_none` flag set to True. |
Method | with |
Produce a copy of this type object that will utilize the given type when applied to the dialect of the given name. |
Class Variable | hashable |
Flag, if False, means values from this type aren't hashable. |
Class Variable | render |
Render bind casts for :attr:`.BindTyping.RENDER_CASTS` mode. |
Class Variable | render |
render casts when rendering a value as an inline literal, e.g. with :meth:`.TypeEngine.literal_processor`. |
Class Variable | should |
If True, the Python constant ``None`` is considered to be handled explicitly by this type. |
Class Variable | sort |
A sorting function that can be passed as the key to sorted. |
Static Method | _to |
Undocumented |
Method | _cached |
Return a dialect-specific bind processor for this type. |
Method | _cached |
return a dialect-specific processing object for custom purposes. |
Method | _cached |
Return a dialect-specific literal processor for this type. |
Method | _cached |
Return a dialect-specific result processor for this type. |
Method | _compare |
Undocumented |
Method | _default |
Undocumented |
Method | _dialect |
Return a dialect-specific registry which caches a dialect-specific implementation, bind processing function, and one or more result processing functions. |
Method | _gen |
Undocumented |
Method | _resolve |
adjust this type given a literal Python value that will be stored in a bound parameter. |
Method | _resolve |
given a Python type (e.g. ``int``, ``str``, etc. ) return an instance of this :class:`.TypeEngine` that's appropriate for this type. |
Method | _unwrapped |
Return the 'unwrapped' dialect impl for this type. |
Class Variable | _is |
Undocumented |
Class Variable | _is |
Undocumented |
Class Variable | _is |
Undocumented |
Class Variable | _is |
Undocumented |
Class Variable | _isnull |
Undocumented |
Class Variable | _sqla |
Undocumented |
Property | _generic |
Undocumented |
Property | _has |
memoized boolean, check if bind_expression is implemented. |
Property | _has |
memoized boolean, check if column_expression is implemented. |
Inherited from Visitable
(via Float
, Numeric
, HasExpressionLookup
, MatchType
, Boolean
, SchemaType
, SchemaEventTarget
, EventTarget
, Emulated
, TypeEngineMixin
, TypeEngine
):
Method | __class |
Undocumented |
Method | __init |
Undocumented |
Class Method | _generate |
Undocumented |
Method | _compiler |
Undocumented |
Class Variable | _original |
Undocumented |
sqlalchemy.sql.sqltypes.Float.__init__
Construct a Float. :param precision: the numeric precision for use in DDL ``CREATE TABLE``. Backends **should** attempt to ensure this precision indicates a number of digits for the generic :class:`_sqltypes.Float` datatype. .. note:: For the Oracle backend, the :paramref:`_sqltypes.Float.precision` parameter is not accepted when rendering DDL, as Oracle does not support float precision specified as a number of decimal places. Instead, use the Oracle-specific :class:`_oracle.FLOAT` datatype and specify the :paramref:`_oracle.FLOAT.binary_precision` parameter. This is new in version 2.0 of SQLAlchemy. To create a database agnostic :class:`_types.Float` that separately specifies binary precision for Oracle, use :meth:`_types.TypeEngine.with_variant` as follows:: from sqlalchemy import Column from sqlalchemy import Float from sqlalchemy.dialects import oracle Column( "float_data", Float(5).with_variant(oracle.FLOAT(binary_precision=16), "oracle") ) :param asdecimal: the same flag as that of :class:`.Numeric`, but defaults to ``False``. Note that setting this flag to ``True`` results in floating point conversion. :param decimal_return_scale: Default scale to use when converting from floats to Python decimals. Floating point values will typically be much longer due to decimal inaccuracy, and most floating point database types don't have a notion of "scale", so by default the float type looks for the first ten decimal places when converting. Specifying this value will override that length. Note that the MySQL float types, which do include "scale", will use "scale" as the default for decimal_return_scale, if not otherwise specified. .. versionadded:: 0.9.0