public static enum SqlStatement.Type extends Enum<SqlStatement.Type>
This type affects which ResultSet
method we use to get values
of this column: the default is ResultSet.getObject(int)
, but we'd prefer to use native values
getInt
and getDouble
if possible.
Note that the DECIMAL type was added to provide a workaround for a bug in the Snowflake JDBC driver. There is no plan to support it further than that.
Enum Constant and Description |
---|
DECIMAL |
DOUBLE |
INT |
LONG |
OBJECT |
STRING |
Modifier and Type | Method and Description |
---|---|
Object |
get(ResultSet resultSet,
int column) |
static SqlStatement.Type |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static SqlStatement.Type[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final SqlStatement.Type OBJECT
public static final SqlStatement.Type DOUBLE
public static final SqlStatement.Type INT
public static final SqlStatement.Type LONG
public static final SqlStatement.Type STRING
public static final SqlStatement.Type DECIMAL
public static SqlStatement.Type[] values()
for (SqlStatement.Type c : SqlStatement.Type.values()) System.out.println(c);
public static SqlStatement.Type valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic Object get(ResultSet resultSet, int column) throws SQLException
SQLException
Copyright © 2020 Hitachi Vantara. All rights reserved.