All Packages Class Hierarchy This Package Previous Next Index
Class JBMSTours.vti.jdbc2_0.ExternalInformixTable
java.lang.Object
|
+----COM.cloudscape.vti.UpdatableVTITemplate
|
+----COM.cloudscape.vti20.UpdatableVTITemplate
|
+----JBMSTours.vti.jdbc2_0.ExternalInformixTable
- public class ExternalInformixTable
- extends UpdatableVTITemplate
A read-write VTI class that gives access to a table in an Informix database.
This class uses EITResult as a wrapper around a JDBC20 updatable ResultSet as the
ResultSet it returns in ExecuteQuery.
Here is an example SQL-J statement using this VTI class as an ExternalVirtualTable:
DELETE FROM NEW JBMSTours.vti.jdbc2_0.ExternalInformixTable(
'jdbc:informix-sqli://janets:1025/toys:INFORMIXSERVER=ol_janets;user=informix;password=informix', * 'toys') WHERE "toy" like '%barbie%';
DO NOT compile or run this class in a pre-JDK 1.2 environment. It requires
JDK 1.2 or above.
-
ExternalInformixTable(String, String)
- Constructs the VTI class.
-
close()
- Explicitly closes this PreparedStatement class.
-
executeQuery()
- Returns a ResultSet (an EITResult) to Cloudscape.
-
getMetaData()
- Provide the metadata for the query against the given table.
-
getResultSetConcurrency()
- Must return java.sql.ResultSet.CONCUR_UPDATABLE to be a read-write VTI class.
ExternalInformixTable
public ExternalInformixTable(String url,
String tableName) throws SQLException
- Constructs the VTI class. Loads the Informix JDBC Driver and constructs
and prepares the query.
- Parameters:
- url - The url of the external Informix database
- tableName - The name of the table
- Throws: SQLException
- on unexpected JDBC error
getResultSetConcurrency
public int getResultSetConcurrency() throws SQLException
- Must return java.sql.ResultSet.CONCUR_UPDATABLE to be a read-write VTI class.
- Throws: SQLException
- on unexpected JDBC error
- Overrides:
- getResultSetConcurrency in class UpdatableVTITemplate
- See Also:
- Statement
executeQuery
public ResultSet executeQuery() throws SQLException
- Returns a ResultSet (an EITResult) to Cloudscape. Cloudscape calls this\
method when it executes the SQL-J statement that uses this VTI class.
- Throws: SQLException
- on unexpected JDBC error
- Overrides:
- executeQuery in class UpdatableVTITemplate
- See Also:
- Statement
getMetaData
public ResultSetMetaData getMetaData() throws SQLException
- Provide the metadata for the query against the given table. Cloudscape
calls this method when it compiles the SQL-J statement that uses this
VTI class.
- Returns:
- the result set metadata for the query
- Throws: SQLException
- thrown by JDBC calls
- Overrides:
- getMetaData in class UpdatableVTITemplate
close
public void close() throws SQLException
- Explicitly closes this PreparedStatement class. (Note: Cloudscape
calls this method only after compiling a SELECT statement that uses
this class.)
- Throws: SQLException
- on unexpected JDBC error
- Overrides:
- close in class UpdatableVTITemplate
- See Also:
- Statement
All Packages Class Hierarchy This Package Previous Next Index