Class PgResultSet
- All Implemented Interfaces:
AutoCloseable
,ResultSet
,Wrapper
,PGRefCursorResultSet
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected boolean
protected final BaseConnection
protected int
protected ResultCursor
protected int
protected final Field[]
protected int
protected final int
protected final int
protected boolean
protected final Query
protected int
protected final BaseStatement
protected Tuple
protected SQLWarning
protected boolean
True if the last obtained column value was SQL NULL as specified bywasNull()
.Fields inherited from interface java.sql.ResultSet
CLOSE_CURSORS_AT_COMMIT, CONCUR_READ_ONLY, CONCUR_UPDATABLE, FETCH_FORWARD, FETCH_REVERSE, FETCH_UNKNOWN, HOLD_CURSORS_OVER_COMMIT, TYPE_FORWARD_ONLY, TYPE_SCROLL_INSENSITIVE, TYPE_SCROLL_SENSITIVE
-
Method Summary
Modifier and TypeMethodDescriptionboolean
absolute
(int index) protected void
addWarning
(SQLWarning warnings) void
void
void
protected void
protected void
checkColumnIndex
(int column) void
void
close()
protected void
createColumnNameIndexMap
(Field[] fields, boolean isSanitiserDisabled) protected ResultSetMetaData
void
int
findColumn
(String columnName) boolean
first()
boolean
Get state of adaptive fetch for resultSet.getArray
(int i) getAsciiStream
(int columnIndex) getAsciiStream
(String columnName) getBigDecimal
(int columnIndex) getBigDecimal
(int columnIndex, int scale) getBigDecimal
(String columnName) getBigDecimal
(String columnName, int scale) getBinaryStream
(int columnIndex) getBinaryStream
(String columnName) getBlob
(int i) boolean
getBoolean
(int columnIndex) Retrieves the value of the designated column in the current row of thisResultSet
object as aboolean
in the Java programming language.boolean
getBoolean
(String columnName) byte
getByte
(int columnIndex) byte
byte[]
getBytes
(int columnIndex) byte[]
getCharacterStream
(int i) getCharacterStream
(String columnName) getClob
(int i) int
getColumnOID
(int field) Returns the OID of a field.int
getDate
(int columnIndex) double
getDouble
(int columnIndex) double
int
int
getFixedString
(int col) This is used to fix get*() methods on Money fields.float
getFloat
(int columnIndex) float
int
int
getInt
(int columnIndex) int
int
Get fetch size used during last fetch.long
getLong
(int columnIndex) long
getNCharacterStream
(int columnIndex) getNCharacterStream
(String columnName) getNClob
(int columnIndex) getNString
(int columnIndex) getNString
(String columnName) getObject
(int columnIndex) <T> T
<T> T
getObjectImpl
(int i, Map<String, Class<?>> map) getObjectImpl
(String columnName, Map<String, Class<?>> map) protected String
getPGType
(int column) protected byte[]
getRawValue
(int column) Checks that the result set is not closed, it's positioned on a valid row and that the given column number is valid.getRef
(int i) int
getRow()
getRowId
(int columnIndex) short
getShort
(int columnIndex) short
protected int
getSQLType
(int column) getSQLXML
(int columnIndex) getString
(int columnIndex) getTime
(int columnIndex) getTimestamp
(int columnIndex) getTimestamp
(int i, Calendar cal) getTimestamp
(String columnName) getTimestamp
(String c, Calendar cal) int
getType()
getUnicodeStream
(int columnIndex) getUnicodeStream
(String columnName) getURL
(int columnIndex) protected Object
getUUID
(byte[] data) protected Object
void
protected Object
internalGetObject
(int columnIndex, Field field) boolean
boolean
protected boolean
isBinary
(int column) Returns true if the value of the given column is in binary format.boolean
isClosed()
boolean
isFirst()
boolean
isLast()
protected boolean
boolean
isWrapperFor
(Class<?> iface) boolean
last()
protected Array
makeArray
(int oid, byte[] value) protected Array
protected Blob
makeBlob
(long oid) protected Clob
makeClob
(long oid) void
void
boolean
next()
boolean
previous()
static String[]
quotelessTableName
(String fullname) Cracks out the table name and schema (if it exists) from a fully qualified table name.void
boolean
relative
(int rows) boolean
boolean
boolean
void
setAdaptiveFetch
(boolean adaptiveFetch) Turn on/off adaptive fetch for ResultSet.void
setFetchDirection
(int direction) void
setFetchSize
(int rows) static BigDecimal
toBigDecimal
(String s, int scale) static double
static float
static int
static long
static short
<T> T
void
updateArray
(int columnIndex, Array x) void
updateArray
(String columnName, Array x) void
updateAsciiStream
(int columnIndex, InputStream inputStream) void
updateAsciiStream
(int columnIndex, InputStream x, int length) void
updateAsciiStream
(int columnIndex, InputStream inputStream, long length) void
updateAsciiStream
(String columnName, InputStream inputStream) void
updateAsciiStream
(String columnName, InputStream x, int length) void
updateAsciiStream
(String columnName, InputStream inputStream, long length) void
updateBigDecimal
(int columnIndex, BigDecimal x) void
updateBigDecimal
(String columnName, BigDecimal x) void
updateBinaryStream
(int columnIndex, InputStream inputStream) void
updateBinaryStream
(int columnIndex, InputStream x, int length) void
updateBinaryStream
(int columnIndex, InputStream inputStream, long length) void
updateBinaryStream
(String columnName, InputStream inputStream) void
updateBinaryStream
(String columnName, InputStream x, int length) void
updateBinaryStream
(String columnName, InputStream inputStream, long length) void
updateBlob
(int columnIndex, InputStream inputStream) void
updateBlob
(int columnIndex, InputStream inputStream, long length) void
updateBlob
(int columnIndex, Blob x) void
updateBlob
(String columnName, InputStream inputStream) void
updateBlob
(String columnName, InputStream inputStream, long length) void
updateBlob
(String columnName, Blob x) void
updateBoolean
(int columnIndex, boolean x) void
updateBoolean
(String columnName, boolean x) void
updateByte
(int columnIndex, byte x) void
updateByte
(String columnName, byte x) void
updateBytes
(int columnIndex, byte[] x) void
updateBytes
(String columnName, byte[] x) void
updateCharacterStream
(int columnIndex, Reader reader) void
updateCharacterStream
(int columnIndex, Reader x, int length) void
updateCharacterStream
(int columnIndex, Reader reader, long length) void
updateCharacterStream
(String columnName, Reader reader) void
updateCharacterStream
(String columnName, Reader reader, int length) void
updateCharacterStream
(String columnName, Reader reader, long length) void
updateClob
(int columnIndex, Reader reader) void
updateClob
(int columnIndex, Reader reader, long length) void
updateClob
(int columnIndex, Clob x) void
updateClob
(String columnName, Reader reader) void
updateClob
(String columnName, Reader reader, long length) void
updateClob
(String columnName, Clob x) void
updateDate
(int columnIndex, Date x) void
updateDate
(String columnName, Date x) void
updateDouble
(int columnIndex, double x) void
updateDouble
(String columnName, double x) void
updateFloat
(int columnIndex, float x) void
updateFloat
(String columnName, float x) void
updateInt
(int columnIndex, int x) void
void
updateLong
(int columnIndex, long x) void
updateLong
(String columnName, long x) void
updateNCharacterStream
(int columnIndex, Reader x) void
updateNCharacterStream
(int columnIndex, Reader x, int length) void
updateNCharacterStream
(int columnIndex, Reader x, long length) void
updateNCharacterStream
(String columnName, Reader x) void
updateNCharacterStream
(String columnName, Reader x, int length) void
updateNCharacterStream
(String columnName, Reader x, long length) void
updateNClob
(int columnIndex, Reader reader) void
updateNClob
(int columnIndex, Reader reader, long length) void
updateNClob
(int columnIndex, NClob nClob) void
updateNClob
(String columnName, Reader reader) void
updateNClob
(String columnName, Reader reader, long length) void
updateNClob
(String columnName, NClob nClob) void
updateNString
(int columnIndex, String nString) void
updateNString
(String columnName, String nString) void
updateNull
(int columnIndex) void
updateNull
(String columnName) void
updateObject
(int columnIndex, Object x) void
updateObject
(int columnIndex, Object x, int scale) void
updateObject
(int columnIndex, Object x, SQLType targetSqlType) void
updateObject
(int columnIndex, Object x, SQLType targetSqlType, int scaleOrLength) void
updateObject
(String columnName, Object x) void
updateObject
(String columnName, Object x, int scale) void
updateObject
(String columnLabel, Object x, SQLType targetSqlType) void
updateObject
(String columnLabel, Object x, SQLType targetSqlType, int scaleOrLength) void
void
void
void
updateRowId
(int columnIndex, RowId x) void
updateRowId
(String columnName, RowId x) void
updateShort
(int columnIndex, short x) void
updateShort
(String columnName, short x) void
updateSQLXML
(int columnIndex, SQLXML xmlObject) void
updateSQLXML
(String columnName, SQLXML xmlObject) void
updateString
(int columnIndex, String x) void
updateString
(String columnName, String x) void
updateTime
(int columnIndex, Time x) void
updateTime
(String columnName, Time x) void
updateTimestamp
(int columnIndex, Timestamp x) void
updateTimestamp
(String columnName, Timestamp x) protected void
updateValue
(int columnIndex, Object value) protected PgResultSet
This is here to be used by metadata functions to make all column labels upper case.boolean
wasNull()
-
Field Details
-
connection
-
statement
-
fields
-
originalQuery
-
maxRows
protected final int maxRows -
maxFieldSize
protected final int maxFieldSize -
rows
-
currentRow
protected int currentRow -
rowOffset
protected int rowOffset -
thisRow
-
warnings
-
wasNullFlag
protected boolean wasNullFlagTrue if the last obtained column value was SQL NULL as specified bywasNull()
. The value is always updated by thegetRawValue(int)
method. -
onInsertRow
protected boolean onInsertRow -
fetchSize
protected int fetchSize -
lastUsedFetchSize
protected int lastUsedFetchSize -
adaptiveFetch
protected boolean adaptiveFetch -
cursor
-
-
Method Details
-
createMetaData
- Throws:
SQLException
-
getMetaData
- Specified by:
getMetaData
in interfaceResultSet
- Throws:
SQLException
-
getURL
- Specified by:
getURL
in interfaceResultSet
- Throws:
SQLException
-
getURL
- Specified by:
getURL
in interfaceResultSet
- Throws:
SQLException
-
internalGetObject
- Throws:
SQLException
-
absolute
- Specified by:
absolute
in interfaceResultSet
- Throws:
SQLException
-
afterLast
- Specified by:
afterLast
in interfaceResultSet
- Throws:
SQLException
-
beforeFirst
- Specified by:
beforeFirst
in interfaceResultSet
- Throws:
SQLException
-
first
- Specified by:
first
in interfaceResultSet
- Throws:
SQLException
-
getArray
- Specified by:
getArray
in interfaceResultSet
- Throws:
SQLException
-
makeArray
- Throws:
SQLException
-
makeArray
- Throws:
SQLException
-
getArray
- Specified by:
getArray
in interfaceResultSet
- Throws:
SQLException
-
getBigDecimal
- Specified by:
getBigDecimal
in interfaceResultSet
- Throws:
SQLException
-
getBigDecimal
- Specified by:
getBigDecimal
in interfaceResultSet
- Throws:
SQLException
-
getBlob
- Specified by:
getBlob
in interfaceResultSet
- Throws:
SQLException
-
makeBlob
- Throws:
SQLException
-
getBlob
- Specified by:
getBlob
in interfaceResultSet
- Throws:
SQLException
-
getCharacterStream
- Specified by:
getCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
getCharacterStream
- Specified by:
getCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
getClob
- Specified by:
getClob
in interfaceResultSet
- Throws:
SQLException
-
makeClob
- Throws:
SQLException
-
getClob
- Specified by:
getClob
in interfaceResultSet
- Throws:
SQLException
-
getConcurrency
- Specified by:
getConcurrency
in interfaceResultSet
- Throws:
SQLException
-
getDate
- Specified by:
getDate
in interfaceResultSet
- Throws:
SQLException
-
getTime
- Specified by:
getTime
in interfaceResultSet
- Throws:
SQLException
-
getTimestamp
- Specified by:
getTimestamp
in interfaceResultSet
- Throws:
SQLException
-
getDate
- Specified by:
getDate
in interfaceResultSet
- Throws:
SQLException
-
getTime
- Specified by:
getTime
in interfaceResultSet
- Throws:
SQLException
-
getTimestamp
- Specified by:
getTimestamp
in interfaceResultSet
- Throws:
SQLException
-
getFetchDirection
- Specified by:
getFetchDirection
in interfaceResultSet
- Throws:
SQLException
-
getObjectImpl
- Throws:
SQLException
-
getObjectImpl
- Throws:
SQLException
-
getRef
- Specified by:
getRef
in interfaceResultSet
- Throws:
SQLException
-
getRef
- Specified by:
getRef
in interfaceResultSet
- Throws:
SQLException
-
getRow
- Specified by:
getRow
in interfaceResultSet
- Throws:
SQLException
-
getStatement
- Specified by:
getStatement
in interfaceResultSet
- Throws:
SQLException
-
getType
- Specified by:
getType
in interfaceResultSet
- Throws:
SQLException
-
isAfterLast
- Specified by:
isAfterLast
in interfaceResultSet
- Throws:
SQLException
-
isBeforeFirst
- Specified by:
isBeforeFirst
in interfaceResultSet
- Throws:
SQLException
-
isFirst
- Specified by:
isFirst
in interfaceResultSet
- Throws:
SQLException
-
isLast
- Specified by:
isLast
in interfaceResultSet
- Throws:
SQLException
-
last
- Specified by:
last
in interfaceResultSet
- Throws:
SQLException
-
previous
- Specified by:
previous
in interfaceResultSet
- Throws:
SQLException
-
relative
- Specified by:
relative
in interfaceResultSet
- Throws:
SQLException
-
setFetchDirection
- Specified by:
setFetchDirection
in interfaceResultSet
- Throws:
SQLException
-
cancelRowUpdates
- Specified by:
cancelRowUpdates
in interfaceResultSet
- Throws:
SQLException
-
deleteRow
- Specified by:
deleteRow
in interfaceResultSet
- Throws:
SQLException
-
insertRow
- Specified by:
insertRow
in interfaceResultSet
- Throws:
SQLException
-
moveToCurrentRow
- Specified by:
moveToCurrentRow
in interfaceResultSet
- Throws:
SQLException
-
moveToInsertRow
- Specified by:
moveToInsertRow
in interfaceResultSet
- Throws:
SQLException
-
rowDeleted
- Specified by:
rowDeleted
in interfaceResultSet
- Throws:
SQLException
-
rowInserted
- Specified by:
rowInserted
in interfaceResultSet
- Throws:
SQLException
-
rowUpdated
- Specified by:
rowUpdated
in interfaceResultSet
- Throws:
SQLException
-
updateAsciiStream
- Specified by:
updateAsciiStream
in interfaceResultSet
- Throws:
SQLException
-
updateBigDecimal
- Specified by:
updateBigDecimal
in interfaceResultSet
- Throws:
SQLException
-
updateBinaryStream
- Specified by:
updateBinaryStream
in interfaceResultSet
- Throws:
SQLException
-
updateBoolean
- Specified by:
updateBoolean
in interfaceResultSet
- Throws:
SQLException
-
updateByte
- Specified by:
updateByte
in interfaceResultSet
- Throws:
SQLException
-
updateBytes
- Specified by:
updateBytes
in interfaceResultSet
- Throws:
SQLException
-
updateCharacterStream
- Specified by:
updateCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateDate
- Specified by:
updateDate
in interfaceResultSet
- Throws:
SQLException
-
updateDouble
- Specified by:
updateDouble
in interfaceResultSet
- Throws:
SQLException
-
updateFloat
- Specified by:
updateFloat
in interfaceResultSet
- Throws:
SQLException
-
updateInt
- Specified by:
updateInt
in interfaceResultSet
- Throws:
SQLException
-
updateLong
- Specified by:
updateLong
in interfaceResultSet
- Throws:
SQLException
-
updateNull
- Specified by:
updateNull
in interfaceResultSet
- Throws:
SQLException
-
updateObject
- Specified by:
updateObject
in interfaceResultSet
- Throws:
SQLException
-
updateObject
- Specified by:
updateObject
in interfaceResultSet
- Throws:
SQLException
-
refreshRow
- Specified by:
refreshRow
in interfaceResultSet
- Throws:
SQLException
-
updateRow
- Specified by:
updateRow
in interfaceResultSet
- Throws:
SQLException
-
updateShort
- Specified by:
updateShort
in interfaceResultSet
- Throws:
SQLException
-
updateString
- Specified by:
updateString
in interfaceResultSet
- Throws:
SQLException
-
updateTime
- Specified by:
updateTime
in interfaceResultSet
- Throws:
SQLException
-
updateTimestamp
- Specified by:
updateTimestamp
in interfaceResultSet
- Throws:
SQLException
-
updateNull
- Specified by:
updateNull
in interfaceResultSet
- Throws:
SQLException
-
updateBoolean
- Specified by:
updateBoolean
in interfaceResultSet
- Throws:
SQLException
-
updateByte
- Specified by:
updateByte
in interfaceResultSet
- Throws:
SQLException
-
updateShort
- Specified by:
updateShort
in interfaceResultSet
- Throws:
SQLException
-
updateInt
- Specified by:
updateInt
in interfaceResultSet
- Throws:
SQLException
-
updateLong
- Specified by:
updateLong
in interfaceResultSet
- Throws:
SQLException
-
updateFloat
- Specified by:
updateFloat
in interfaceResultSet
- Throws:
SQLException
-
updateDouble
- Specified by:
updateDouble
in interfaceResultSet
- Throws:
SQLException
-
updateBigDecimal
- Specified by:
updateBigDecimal
in interfaceResultSet
- Throws:
SQLException
-
updateString
- Specified by:
updateString
in interfaceResultSet
- Throws:
SQLException
-
updateBytes
- Specified by:
updateBytes
in interfaceResultSet
- Throws:
SQLException
-
updateDate
- Specified by:
updateDate
in interfaceResultSet
- Throws:
SQLException
-
updateTime
- Specified by:
updateTime
in interfaceResultSet
- Throws:
SQLException
-
updateTimestamp
- Specified by:
updateTimestamp
in interfaceResultSet
- Throws:
SQLException
-
updateAsciiStream
- Specified by:
updateAsciiStream
in interfaceResultSet
- Throws:
SQLException
-
updateBinaryStream
- Specified by:
updateBinaryStream
in interfaceResultSet
- Throws:
SQLException
-
updateCharacterStream
- Specified by:
updateCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateObject
- Specified by:
updateObject
in interfaceResultSet
- Throws:
SQLException
-
updateObject
- Specified by:
updateObject
in interfaceResultSet
- Throws:
SQLException
-
setAdaptiveFetch
Turn on/off adaptive fetch for ResultSet.- Parameters:
adaptiveFetch
- desired state of adaptive fetch.- Throws:
SQLException
- exception returned if ResultSet is closed
-
getAdaptiveFetch
Get state of adaptive fetch for resultSet.- Returns:
- state of adaptive fetch (turned on or off)
- Throws:
SQLException
- exception returned if ResultSet is closed
-
quotelessTableName
Cracks out the table name and schema (if it exists) from a fully qualified table name.- Parameters:
fullname
- string that we are trying to crack. Test cases:Table: table () "Table": Table () Schema.Table: table (schema) "Schema"."Table": Table (Schema) "Schema"."Dot.Table": Dot.Table (Schema) Schema."Dot.Table": Dot.Table (schema)
- Returns:
- String array with element zero always being the tablename and element 1 the schema name which may be a zero length string.
-
getPGStatement
-
getRefCursor
- Specified by:
getRefCursor
in interfacePGRefCursorResultSet
- Returns:
- the name of the cursor.
-
setFetchSize
- Specified by:
setFetchSize
in interfaceResultSet
- Throws:
SQLException
-
getFetchSize
- Specified by:
getFetchSize
in interfaceResultSet
- Throws:
SQLException
-
getLastUsedFetchSize
Get fetch size used during last fetch. Returned value can be useful if using adaptive fetch.- Returns:
- fetch size used during last fetch.
- Throws:
SQLException
- exception returned if ResultSet is closed
-
next
- Specified by:
next
in interfaceResultSet
- Throws:
SQLException
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceResultSet
- Throws:
SQLException
-
closeInternally
- Throws:
SQLException
-
wasNull
- Specified by:
wasNull
in interfaceResultSet
- Throws:
SQLException
-
getString
- Specified by:
getString
in interfaceResultSet
- Throws:
SQLException
-
getBoolean
Retrieves the value of the designated column in the current row of this
ResultSet
object as aboolean
in the Java programming language.If the designated column has a Character datatype and is one of the following values: "1", "true", "t", "yes", "y" or "on", a value of
true
is returned. If the designated column has a Character datatype and is one of the following values: "0", "false", "f", "no", "n" or "off", a value offalse
is returned. Leading or trailing whitespace is ignored, and case does not matter.If the designated column has a Numeric datatype and is a 1, a value of
true
is returned. If the designated column has a Numeric datatype and is a 0, a value offalse
is returned.- Specified by:
getBoolean
in interfaceResultSet
- Parameters:
columnIndex
- the first column is 1, the second is 2, ...- Returns:
- the column value; if the value is SQL
NULL
, the value returned isfalse
- Throws:
SQLException
- if the columnIndex is not valid; if a database access error occurs; if this method is called on a closed result set or is an invalid cast to boolean type.- See Also:
-
getByte
- Specified by:
getByte
in interfaceResultSet
- Throws:
SQLException
-
getShort
- Specified by:
getShort
in interfaceResultSet
- Throws:
SQLException
-
getInt
- Specified by:
getInt
in interfaceResultSet
- Throws:
SQLException
-
getLong
- Specified by:
getLong
in interfaceResultSet
- Throws:
SQLException
-
getFloat
- Specified by:
getFloat
in interfaceResultSet
- Throws:
SQLException
-
getDouble
- Specified by:
getDouble
in interfaceResultSet
- Throws:
SQLException
-
getBigDecimal
- Specified by:
getBigDecimal
in interfaceResultSet
- Throws:
SQLException
-
getBytes
In normal use, the bytes represent the raw values returned by the backend. However, if the column is an OID, then it is assumed to refer to a Large Object, and that object is returned as a byte array.
Be warned If the large object is huge, then you may run out of memory.
- Specified by:
getBytes
in interfaceResultSet
- Throws:
SQLException
-
getDate
- Specified by:
getDate
in interfaceResultSet
- Throws:
SQLException
-
getTime
- Specified by:
getTime
in interfaceResultSet
- Throws:
SQLException
-
getTimestamp
- Specified by:
getTimestamp
in interfaceResultSet
- Throws:
SQLException
-
getAsciiStream
- Specified by:
getAsciiStream
in interfaceResultSet
- Throws:
SQLException
-
getUnicodeStream
- Specified by:
getUnicodeStream
in interfaceResultSet
- Throws:
SQLException
-
getBinaryStream
- Specified by:
getBinaryStream
in interfaceResultSet
- Throws:
SQLException
-
getString
- Specified by:
getString
in interfaceResultSet
- Throws:
SQLException
-
getBoolean
- Specified by:
getBoolean
in interfaceResultSet
- Throws:
SQLException
-
getByte
- Specified by:
getByte
in interfaceResultSet
- Throws:
SQLException
-
getShort
- Specified by:
getShort
in interfaceResultSet
- Throws:
SQLException
-
getInt
- Specified by:
getInt
in interfaceResultSet
- Throws:
SQLException
-
getLong
- Specified by:
getLong
in interfaceResultSet
- Throws:
SQLException
-
getFloat
- Specified by:
getFloat
in interfaceResultSet
- Throws:
SQLException
-
getDouble
- Specified by:
getDouble
in interfaceResultSet
- Throws:
SQLException
-
getBigDecimal
- Specified by:
getBigDecimal
in interfaceResultSet
- Throws:
SQLException
-
getBytes
- Specified by:
getBytes
in interfaceResultSet
- Throws:
SQLException
-
getDate
- Specified by:
getDate
in interfaceResultSet
- Throws:
SQLException
-
getTime
- Specified by:
getTime
in interfaceResultSet
- Throws:
SQLException
-
getTimestamp
- Specified by:
getTimestamp
in interfaceResultSet
- Throws:
SQLException
-
getAsciiStream
- Specified by:
getAsciiStream
in interfaceResultSet
- Throws:
SQLException
-
getUnicodeStream
- Specified by:
getUnicodeStream
in interfaceResultSet
- Throws:
SQLException
-
getBinaryStream
- Specified by:
getBinaryStream
in interfaceResultSet
- Throws:
SQLException
-
getWarnings
- Specified by:
getWarnings
in interfaceResultSet
- Throws:
SQLException
-
clearWarnings
- Specified by:
clearWarnings
in interfaceResultSet
- Throws:
SQLException
-
addWarning
-
getCursorName
- Specified by:
getCursorName
in interfaceResultSet
- Throws:
SQLException
-
getObject
- Specified by:
getObject
in interfaceResultSet
- Throws:
SQLException
-
getObject
- Specified by:
getObject
in interfaceResultSet
- Throws:
SQLException
-
findColumn
- Specified by:
findColumn
in interfaceResultSet
- Throws:
SQLException
-
createColumnNameIndexMap
-
getColumnOID
public int getColumnOID(int field) Returns the OID of a field. It is used internally by the driver.- Parameters:
field
- field index- Returns:
- OID of a field
-
getFixedString
This is used to fix get*() methods on Money fields. It should only be used by those methods!
It converts ($##.##) to -##.## and $##.## to ##.##
- Parameters:
col
- column position (1-based)- Returns:
- numeric-parsable representation of money string literal
- Throws:
SQLException
- if something wrong happens
-
getPGType
- Throws:
SQLException
-
getSQLType
- Throws:
SQLException
-
checkClosed
- Throws:
SQLException
-
isResultSetClosed
protected boolean isResultSetClosed() -
checkColumnIndex
- Throws:
SQLException
-
getRawValue
Checks that the result set is not closed, it's positioned on a valid row and that the given column number is valid. Also updates thewasNullFlag
to correct value.- Parameters:
column
- The column number to check. Range starts from 1.- Returns:
- raw value or null
- Throws:
SQLException
- If state or column is invalid.
-
isBinary
protected boolean isBinary(int column) Returns true if the value of the given column is in binary format.- Parameters:
column
- The column to check. Range starts from 1.- Returns:
- True if the column is in binary format.
-
toShort
- Throws:
SQLException
-
toInt
- Throws:
SQLException
-
toLong
- Throws:
SQLException
-
toBigDecimal
- Throws:
SQLException
-
toBigDecimal
- Throws:
SQLException
-
toFloat
- Throws:
SQLException
-
toDouble
- Throws:
SQLException
-
updateValue
- Throws:
SQLException
-
getUUID
- Throws:
SQLException
-
getUUID
- Throws:
SQLException
-
updateRef
- Specified by:
updateRef
in interfaceResultSet
- Throws:
SQLException
-
updateRef
- Specified by:
updateRef
in interfaceResultSet
- Throws:
SQLException
-
updateBlob
- Specified by:
updateBlob
in interfaceResultSet
- Throws:
SQLException
-
updateBlob
- Specified by:
updateBlob
in interfaceResultSet
- Throws:
SQLException
-
updateClob
- Specified by:
updateClob
in interfaceResultSet
- Throws:
SQLException
-
updateClob
- Specified by:
updateClob
in interfaceResultSet
- Throws:
SQLException
-
updateArray
- Specified by:
updateArray
in interfaceResultSet
- Throws:
SQLException
-
updateArray
- Specified by:
updateArray
in interfaceResultSet
- Throws:
SQLException
-
getObject
- Specified by:
getObject
in interfaceResultSet
- Throws:
SQLException
-
getObject
- Specified by:
getObject
in interfaceResultSet
- Throws:
SQLException
-
getObject
- Specified by:
getObject
in interfaceResultSet
- Throws:
SQLException
-
getObject
- Specified by:
getObject
in interfaceResultSet
- Throws:
SQLException
-
updateObject
public void updateObject(int columnIndex, Object x, SQLType targetSqlType, int scaleOrLength) throws SQLException - Specified by:
updateObject
in interfaceResultSet
- Throws:
SQLException
-
updateObject
public void updateObject(String columnLabel, Object x, SQLType targetSqlType, int scaleOrLength) throws SQLException - Specified by:
updateObject
in interfaceResultSet
- Throws:
SQLException
-
updateObject
- Specified by:
updateObject
in interfaceResultSet
- Throws:
SQLException
-
updateObject
- Specified by:
updateObject
in interfaceResultSet
- Throws:
SQLException
-
getRowId
- Specified by:
getRowId
in interfaceResultSet
- Throws:
SQLException
-
getRowId
- Specified by:
getRowId
in interfaceResultSet
- Throws:
SQLException
-
updateRowId
- Specified by:
updateRowId
in interfaceResultSet
- Throws:
SQLException
-
updateRowId
- Specified by:
updateRowId
in interfaceResultSet
- Throws:
SQLException
-
getHoldability
- Specified by:
getHoldability
in interfaceResultSet
- Throws:
SQLException
-
isClosed
- Specified by:
isClosed
in interfaceResultSet
- Throws:
SQLException
-
updateNString
- Specified by:
updateNString
in interfaceResultSet
- Throws:
SQLException
-
updateNString
- Specified by:
updateNString
in interfaceResultSet
- Throws:
SQLException
-
updateNClob
- Specified by:
updateNClob
in interfaceResultSet
- Throws:
SQLException
-
updateNClob
- Specified by:
updateNClob
in interfaceResultSet
- Throws:
SQLException
-
updateNClob
- Specified by:
updateNClob
in interfaceResultSet
- Throws:
SQLException
-
updateNClob
- Specified by:
updateNClob
in interfaceResultSet
- Throws:
SQLException
-
updateNClob
- Specified by:
updateNClob
in interfaceResultSet
- Throws:
SQLException
-
updateNClob
- Specified by:
updateNClob
in interfaceResultSet
- Throws:
SQLException
-
getNClob
- Specified by:
getNClob
in interfaceResultSet
- Throws:
SQLException
-
getNClob
- Specified by:
getNClob
in interfaceResultSet
- Throws:
SQLException
-
updateBlob
- Specified by:
updateBlob
in interfaceResultSet
- Throws:
SQLException
-
updateBlob
- Specified by:
updateBlob
in interfaceResultSet
- Throws:
SQLException
-
updateBlob
- Specified by:
updateBlob
in interfaceResultSet
- Throws:
SQLException
-
updateBlob
- Specified by:
updateBlob
in interfaceResultSet
- Throws:
SQLException
-
updateClob
- Specified by:
updateClob
in interfaceResultSet
- Throws:
SQLException
-
updateClob
- Specified by:
updateClob
in interfaceResultSet
- Throws:
SQLException
-
updateClob
- Specified by:
updateClob
in interfaceResultSet
- Throws:
SQLException
-
updateClob
- Specified by:
updateClob
in interfaceResultSet
- Throws:
SQLException
-
getSQLXML
- Specified by:
getSQLXML
in interfaceResultSet
- Throws:
SQLException
-
getSQLXML
- Specified by:
getSQLXML
in interfaceResultSet
- Throws:
SQLException
-
updateSQLXML
- Specified by:
updateSQLXML
in interfaceResultSet
- Throws:
SQLException
-
updateSQLXML
- Specified by:
updateSQLXML
in interfaceResultSet
- Throws:
SQLException
-
getNString
- Specified by:
getNString
in interfaceResultSet
- Throws:
SQLException
-
getNString
- Specified by:
getNString
in interfaceResultSet
- Throws:
SQLException
-
getNCharacterStream
- Specified by:
getNCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
getNCharacterStream
- Specified by:
getNCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateNCharacterStream
- Throws:
SQLException
-
updateNCharacterStream
- Throws:
SQLException
-
updateNCharacterStream
- Specified by:
updateNCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateNCharacterStream
- Specified by:
updateNCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateNCharacterStream
- Specified by:
updateNCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateNCharacterStream
- Specified by:
updateNCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateCharacterStream
- Specified by:
updateCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateCharacterStream
public void updateCharacterStream(String columnName, Reader reader, long length) throws SQLException - Specified by:
updateCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateCharacterStream
- Specified by:
updateCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateCharacterStream
- Specified by:
updateCharacterStream
in interfaceResultSet
- Throws:
SQLException
-
updateBinaryStream
public void updateBinaryStream(int columnIndex, InputStream inputStream, long length) throws SQLException - Specified by:
updateBinaryStream
in interfaceResultSet
- Throws:
SQLException
-
updateBinaryStream
public void updateBinaryStream(String columnName, InputStream inputStream, long length) throws SQLException - Specified by:
updateBinaryStream
in interfaceResultSet
- Throws:
SQLException
-
updateBinaryStream
- Specified by:
updateBinaryStream
in interfaceResultSet
- Throws:
SQLException
-
updateBinaryStream
- Specified by:
updateBinaryStream
in interfaceResultSet
- Throws:
SQLException
-
updateAsciiStream
public void updateAsciiStream(int columnIndex, InputStream inputStream, long length) throws SQLException - Specified by:
updateAsciiStream
in interfaceResultSet
- Throws:
SQLException
-
updateAsciiStream
public void updateAsciiStream(String columnName, InputStream inputStream, long length) throws SQLException - Specified by:
updateAsciiStream
in interfaceResultSet
- Throws:
SQLException
-
updateAsciiStream
- Specified by:
updateAsciiStream
in interfaceResultSet
- Throws:
SQLException
-
updateAsciiStream
- Specified by:
updateAsciiStream
in interfaceResultSet
- Throws:
SQLException
-
isWrapperFor
- Specified by:
isWrapperFor
in interfaceWrapper
- Throws:
SQLException
-
unwrap
- Specified by:
unwrap
in interfaceWrapper
- Throws:
SQLException
-
upperCaseFieldLabels
This is here to be used by metadata functions to make all column labels upper case. Because postgres folds columns to lower case in queries it will be easier to change the fields after the fact rather than try to coerce all the columns to upper case in the queries as this would require surrounding all columns with " and escaping them making them even harder to read than they are now.- Returns:
- PgResultSet
-