|
SolarMetric Kodo JDO 2.5.8 generated on January 11 2004 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--com.solarmetric.kodo.impl.jdbc.schema.dict.AbstractDictionary
|
+--com.solarmetric.kodo.impl.jdbc.schema.dict.OracleDictionary
Implementation of the DBDictionary interface for Oracle.
| Inner Class Summary | |
static class |
OracleDictionary.EmbeddedLob
|
| Field Summary | |
(package private) boolean |
checkedDriverForUpdateBug
|
static String |
EMPTY_BLOB_STRING
|
static String |
EMPTY_CLOB_STRING
|
(package private) boolean |
isOracleJDBCDriver
This parameter affects whether we will use the special Blob and Clob handling required by the Oracle JDBC driver. |
| Fields inherited from class com.solarmetric.kodo.impl.jdbc.schema.dict.AbstractDictionary |
CENTI, DECI, meta, MICRO, MILLI, NANO, NUMBER_FORMAT, SEC |
| Constructor Summary | |
OracleDictionary()
|
|
| Method Summary | |
Object |
blobFromSQL(ResultSet rs,
int column)
Convert the specified column of the SQL ResultSet to the proper java type. |
void |
blobToPreparedParameter(PreparedStatement st,
int i,
Object o)
|
void |
blobToPreparedParameterOracle(PreparedStatement st,
int i,
Object o)
Oracle requires special handling of Blobs. |
Object |
blobToSQL(Object val)
Convert data into SQL for the current database platform. |
String |
clobFromSQL(ResultSet rs,
int column)
Convert the specified column of the SQL ResultSet to the proper java type. |
void |
clobToPreparedParameter(PreparedStatement st,
int i,
Object clob)
|
void |
clobToPreparedParameterOracle(PreparedStatement st,
int i,
Object clob)
The Oracle JDBC driver requires special handling of Clobs. |
Object |
clobToSQL(Object val)
Convert data into SQL for the current database platform. |
void |
endConfiguration()
Invoked upon completion of configuration of this object |
ResultSet |
getColumns(String tableName,
Connection conn)
Oracle is very slow when retrieving column information from DatabaseMetaData. |
SQLBuffer[] |
getDropColumnSQL(Column column)
Return a series of SQL statements to drop the given column from its table, including the deletion of any indices from the column. |
int |
getEmbeddedBlobMaxLength()
Returns the maximum blob length (in bytes) that can be embedded in a prepared statement without any special handling. |
int |
getEmbeddedClobMaxLength()
Returns the maximum clob length (in characters) that can be embedded in a prepared statement without any special handling. |
Class[] |
getFieldMappingCandidateClasses()
Returns a list of possible FieldMapping
classes for use with this DBDictionary. |
boolean |
getIsOracleJDBCDriver()
Get whether this is using the Oracle JDBC driver, or another vendor's driver. |
String |
getNonSQL92LeftOuterJoin(String fromTableAlias,
Column[] fromCols,
String toTableAlias,
Column[] toCols)
Throws an unsupported option exception by default. |
String |
getPlatform()
Return the title of this database platform, used for display only. |
boolean |
isDataDirectJDBCDriver()
|
void |
setEmbeddedBlobMaxLength(int l)
Sets the maximum blob length (in bytes) that can be embedded in a prepared statement without any special handling. |
void |
setEmbeddedClobMaxLength(int l)
Sets the maximum clob length (in characters) that can be embedded in a prepared statement without any special handling. |
void |
setIsOracleJDBCDriver(boolean isOracleJDBCDriver)
Set whether this is using the Oracle JDBC driver, or another vendor's driver. |
protected void |
setupSQLTypeMap(SQLTypeMap map)
This is the most commonly overridden method when porting to a new database. |
void |
startConfiguration()
Invoked before configuration is begun on this object |
boolean |
supportsLocking()
We do support locking, but check here for a bug in some versions of the DataDirect driver that prevents the correct number of rows from being returned in "SELECT ... |
boolean |
supportsNonSQL92LeftOuterJoins()
Returns false by default. |
boolean |
supportsUpdateCountsForBatch()
Oracle always returns an array of -2 values for any call to Statement.executeBatch(). |
SQLBuffer |
toSelect(String[] cols,
String[] tables,
SQLBuffer where,
SQLBuffer order,
boolean dstnct,
boolean update)
Appends the given pieces using standard SQL. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
boolean isOracleJDBCDriver
boolean checkedDriverForUpdateBug
public static final String EMPTY_BLOB_STRING
public static final String EMPTY_CLOB_STRING
| Constructor Detail |
public OracleDictionary()
| Method Detail |
public boolean supportsNonSQL92LeftOuterJoins()
AbstractDictionarysupportsNonSQL92LeftOuterJoins in class AbstractDictionary
public String getNonSQL92LeftOuterJoin(String fromTableAlias,
Column[] fromCols,
String toTableAlias,
Column[] toCols)
AbstractDictionarygetNonSQL92LeftOuterJoin in class AbstractDictionary
public SQLBuffer toSelect(String[] cols,
String[] tables,
SQLBuffer where,
SQLBuffer order,
boolean dstnct,
boolean update)
AbstractDictionarytoSelect in class AbstractDictionarycom.solarmetric.kodo.impl.jdbc.schema.DBDictionarycols - list of values the columns to selecttables - list of the tables to select fromwhere - the WHERE conditions; may be null if noneorder - the ORDER BY conditions; may be null if nonedistinct - if true, this should be a SELECT DISTINCT-equivalent
queryupdate - if true this should be a SELECT FOR
UPDATE-equivalent querypublic boolean isDataDirectJDBCDriver()
public boolean supportsLocking()
supportsLocking in class AbstractDictionarypublic String getPlatform()
AbstractDictionarygetPlatform in class AbstractDictionarypublic Object blobToSQL(Object val)
DBDictionaryblobToSQL in class AbstractDictionarypublic Object clobToSQL(Object val)
DBDictionaryclobToSQL in class AbstractDictionary
public Object blobFromSQL(ResultSet rs,
int column)
throws SQLException
DBDictionaryblobFromSQL in class AbstractDictionary
public void blobToPreparedParameter(PreparedStatement st,
int i,
Object o)
throws SQLException
blobToPreparedParameter in class AbstractDictionary
public void blobToPreparedParameterOracle(PreparedStatement st,
int i,
Object o)
throws SQLException
Blobs.
public String clobFromSQL(ResultSet rs,
int column)
throws SQLException
DBDictionaryclobFromSQL in class AbstractDictionary
public void clobToPreparedParameter(PreparedStatement st,
int i,
Object clob)
throws SQLException
clobToPreparedParameter in class AbstractDictionary
public void clobToPreparedParameterOracle(PreparedStatement st,
int i,
Object clob)
throws SQLException
Clobs.public SQLBuffer[] getDropColumnSQL(Column column)
DBDictionarygetDropColumnSQL in class AbstractDictionaryprotected void setupSQLTypeMap(SQLTypeMap map)
AbstractDictionarysetupSQLTypeMap in class AbstractDictionarypublic Class[] getFieldMappingCandidateClasses()
DBDictionaryFieldMapping
classes for use with this DBDictionary.getFieldMappingCandidateClasses in class AbstractDictionary
public ResultSet getColumns(String tableName,
Connection conn)
throws SQLException
DatabaseMetaData. Since we only need the
"COLUMN_NAME" and "TABLE_NAME" fields as the contract for
this method, we merely return the the result of the following
SQL:
SELECT TABLE_NAME, COLUMN_NAME FROM USER_TAB_COLUMNS WHERE
TABLE_NAME LIKE 'tableName'
getColumns in class AbstractDictionarypublic boolean supportsUpdateCountsForBatch()
Statement.executeBatch().supportsUpdateCountsForBatch in class AbstractDictionarypublic void startConfiguration()
ConfigurablestartConfiguration in interface Configurablepublic void endConfiguration()
ConfigurableendConfiguration in interface Configurablepublic void setIsOracleJDBCDriver(boolean isOracleJDBCDriver)
Clobs and
Blobs are handled; the Oracle JDBC driver requires
special handling of these types.public boolean getIsOracleJDBCDriver()
Clobs and
Blobs are handled; the Oracle JDBC driver requires
special handling of these types.public void setEmbeddedBlobMaxLength(int l)
public int getEmbeddedBlobMaxLength()
public void setEmbeddedClobMaxLength(int l)
public int getEmbeddedClobMaxLength()
|
SolarMetric Kodo JDO 2.5.8 generated on January 11 2004 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||