OdbcParameterMetaData
class in package klyn.databases.sql.odbc

    public class OdbcParameterMetaData implements ParameterMetaData:

OdbcParameterMetaData
All Implemented Interfaces: ParameterMetaData

Parameter metadata for ODBC prepared statements.

ODBC drivers do not all expose parameter descriptors consistently, so this implementation reports the parameter count known from the SQL text and uses the values bound through the Klyn API to infer type information.

    import klyn.databases.sql

    # prepared = connection.prepared("select * from users where id = ?")
    # print(prepared.parameterInfo.parameterCount)

Properties

Modifier and Type | Member | Description
--- | --- | ---
public readonly property | parameterCount `parameterCount as Int:` | Number of parameters declared in the SQL text.

Inherited Properties
property Inherited Properties from ParameterMetaData: parameterCount
Methods

Modifier and Type | Member | Description
--- | --- | ---
public | getParameterCount `getParameterCount() as Int:` | Returns the number of parameters declared in the SQL text.
public | getParameterMode `getParameterMode(index as Int) as ParameterMode throws SQLException:` | Returns the parameter mode.
public | getParameterType `getParameterType(index as Int) as Int throws SQLException:` | Returns the SQL type code inferred for a parameter.
public | getParameterTypeName `getParameterTypeName(index as Int) as String throws SQLException:` | Returns the SQL type name inferred for a parameter.
public | getPrecision `getPrecision(index as Int) as Int throws SQLException:` | Returns the textual precision inferred for a parameter.
public | getScale `getScale(index as Int) as Int throws SQLException:` | Returns numeric scale for a parameter.
public | isNullable `isNullable(index as Int) as Nullability throws SQLException:` | Returns the nullability contract for a parameter.
public | isSigned `isSigned(index as Int) as Boolean throws SQLException:` | Returns true for signed numeric parameters.
public | nullability `nullability(index as Int) as Nullability throws SQLException:` | Returns the nullability contract for a parameter.
public | parameterMode `parameterMode(index as Int) as ParameterMode throws SQLException:` | Returns the parameter mode.
public | parameterType `parameterType(index as Int) as Int throws SQLException:` | Returns the SQL type code inferred for a parameter.
public | parameterTypeName `parameterTypeName(index as Int) as String throws SQLException:` | Returns the SQL type name inferred for a parameter.
public | precision `precision(index as Int) as Int throws SQLException:` | Returns the textual precision inferred for a parameter.
public | scale `scale(index as Int) as Int throws SQLException:` | Returns numeric scale for a parameter.
public | signed `signed(index as Int) as Boolean throws SQLException:` | Returns true for signed numeric parameters.

Inherited Methods
method Inherited Methods from ParameterMetaData: getParameterCount, getParameterMode, getParameterType, getParameterTypeName, getPrecision, getScale, isNullable, isSigned, nullability, parameterMode, parameterType, parameterTypeName, precision, scale, signed