Name
Clob
Synopsis
Interface Name:
java.sql.Clob
Superclass: None
Immediate Subclasses: None
Interfaces Implemented: None
Availability: New as of JDK 1.2
Description
A CLOB
is an SQL3 type that stands for
“character large object.” Like a BLOB
,
a CLOB
represents a very large chunk of data in
the database. Unlike a BLOB
, it represents text
stored using some sort of character encoding. The point of a
CLOB
type, as opposed to a CHAR
or VARCHAR
type, is that CLOB
data, like BLOB
data, can be retrieved as a stream
instead of all at once.
Class Summary
public interface Clob { InputStream getAsciiStream( ) throws SQLException; Reader getCharacterStream( ) throws SQLException; String getSubString(long pos, int count) throws SQLException; long length( ) throws SQLException; long position(String pattern, long start) throws SQLException; long position(Clob pattern, long start) throws SQLException; }
Object Methods
getAsciiStream( )
public InputStream getAsciiStream( ) throws SQLException
- Description
This method provides access to the data that makes up this
Clob
via an ASCII stream.
getCharacterStream( )
public Reader getCharacterStream( ) throws SQLException
- Description
This method provides access to the data that makes up this
Clob
via a Unicode stream.
getSubString( )
public String getSubString(long pos, int count) throws SQLException
- Description
This method returns a substring of the
Clob
starting at the named position up to the number of characters specified by thecount
value.
length( )
public long length( ...
Get Database Programming with JDBC & Java, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.