public class DbUtil
extends java.lang.Object
| Constructor and Description |
|---|
DbUtil() |
| Modifier and Type | Method and Description |
|---|---|
static void |
close(java.sql.ResultSet resultSet)
Closes result set safely without throwing an exception.
|
static void |
close(java.sql.Statement statement)
Closes statement safely without throwing an exception.
|
static int |
getFirstInt(java.sql.ResultSet resultSet)
Returns int value of very first column in result set.
|
static long |
getFirstLong(java.sql.ResultSet resultSet)
Returns long value of very first column in result set.
|
static void |
setPreparedStatementObject(java.sql.PreparedStatement preparedStatement,
int index,
java.lang.Object value,
int targetSqlType)
Sets prepared statement object using target SQL type.
|
public static void close(java.sql.Statement statement)
public static void close(java.sql.ResultSet resultSet)
public static long getFirstLong(java.sql.ResultSet resultSet)
throws java.sql.SQLException
java.sql.SQLExceptionpublic static int getFirstInt(java.sql.ResultSet resultSet)
throws java.sql.SQLException
java.sql.SQLExceptionpublic static void setPreparedStatementObject(java.sql.PreparedStatement preparedStatement,
int index,
java.lang.Object value,
int targetSqlType)
throws java.sql.SQLException
java.sql.SQLExceptionCopyright © 2003-present Jodd Team