|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.datanucleus.store.rdbms.adapter.DatabaseAdapter
org.datanucleus.store.rdbms.adapter.InformixAdapter
public class InformixAdapter
Provides methods for adapting SQL language elements to the Informix database. Overrides some methods in DatabaseAdapter where Informix behaviour differs. Informix databases must be created WITH LOG MODE ANSI, otherwise errors like "Transaction Not Supported", "Not in transaction" will appear. See the informix info.
| Field Summary |
|---|
| Fields inherited from class org.datanucleus.store.rdbms.adapter.DatabaseAdapter |
|---|
catalogSeparator, datastoreMajorVersion, datastoreMinorVersion, datastoreProductName, datastoreProductVersion, datastoreRevisionVersion, driverMajorVersion, driverMinorVersion, driverName, driverVersion, identifierQuoteString, LOCALISER, LOCALISER_BASE, maxColumnNameLength, maxConstraintNameLength, maxIndexNameLength, maxTableNameLength, properties, reservedKeywords, supportedOptions |
| Fields inherited from interface org.datanucleus.store.mapped.DatastoreAdapter |
|---|
ANALYSIS_METHODS, BIT_IS_REALLY_BOOLEAN, BOOLEAN_COMPARISON, CATALOGS_IN_TABLE_DEFINITIONS, ESCAPE_EXPRESSION_IN_LIKE_PREDICATE, IDENTIFIERS_LOWERCASE, IDENTIFIERS_LOWERCASE_QUOTED, IDENTIFIERS_MIXEDCASE, IDENTIFIERS_MIXEDCASE_QUOTED, IDENTIFIERS_MIXEDCASE_QUOTED_SENSITIVE, IDENTIFIERS_MIXEDCASE_SENSITIVE, IDENTIFIERS_UPPERCASE, IDENTIFIERS_UPPERCASE_QUOTED, IDENTITY_COLUMNS, PROJECTION_IN_TABLE_REFERENCE_JOINS, SCHEMAS_IN_TABLE_DEFINITIONS, SEQUENCES |
| Constructor Summary | |
|---|---|
InformixAdapter(DatabaseMetaData metadata)
Constructor. |
|
| Method Summary | |
|---|---|
String |
getAddCandidateKeyStatement(CandidateKey ck,
org.datanucleus.store.mapped.IdentifierFactory factory)
Returns the appropriate SQL to add a candidate key to its table. |
String |
getAddForeignKeyStatement(ForeignKey fk,
org.datanucleus.store.mapped.IdentifierFactory factory)
Returns the appropriate SQL to add a foreign key to its table. |
String |
getAddPrimaryKeyStatement(PrimaryKey pk,
org.datanucleus.store.mapped.IdentifierFactory factory)
Informix 11.x does not support ALTER TABLE to define a primary key |
String |
getAutoIncrementKeyword()
Accessor for the auto-increment keyword for generating DDLs (CREATE TABLEs...). |
String |
getAutoIncrementStmt(Table table,
String columnName)
Accessor for the autoincrement sql access statement for this datastore. |
String |
getDatastoreDateStatement()
Accessor for a statement that will return the statement to use to get the datastore date. |
String |
getIdentifierQuoteString()
Accessor for an identifier quote string. |
String |
getVendorID()
|
void |
initialiseDatastore(Object conn)
Creates the auxiliary functions/procedures in the schema |
boolean |
isStatementTimeout(SQLException sqle)
return whether this exception represents a timed out statement. |
SQLTypeInfo |
newSQLTypeInfo(ResultSet rs)
Create a new SQL type info from the current row of the passed ResultSet. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public InformixAdapter(DatabaseMetaData metadata)
metadata - MetaData for the DB| Method Detail |
|---|
public void initialiseDatastore(Object conn)
initialiseDatastore in interface org.datanucleus.store.mapped.DatastoreAdapterinitialiseDatastore in class DatabaseAdapterconn - the connection to the datastorepublic String getVendorID()
getVendorID in interface org.datanucleus.store.mapped.DatastoreAdaptergetVendorID in class DatabaseAdapterpublic SQLTypeInfo newSQLTypeInfo(ResultSet rs)
RDBMSAdapter
newSQLTypeInfo in interface RDBMSAdapternewSQLTypeInfo in class DatabaseAdapterrs - ResultSet
public String getIdentifierQuoteString()
getIdentifierQuoteString in interface org.datanucleus.store.mapped.DatastoreAdaptergetIdentifierQuoteString in class DatabaseAdapter
public String getAutoIncrementStmt(Table table,
String columnName)
getAutoIncrementStmt in interface RDBMSAdaptergetAutoIncrementStmt in class DatabaseAdaptertable - Name of the table that the autoincrement is forcolumnName - Name of the column that the autoincrement is for
public String getAutoIncrementKeyword()
getAutoIncrementKeyword in interface RDBMSAdaptergetAutoIncrementKeyword in class DatabaseAdapter
public String getAddPrimaryKeyStatement(PrimaryKey pk,
org.datanucleus.store.mapped.IdentifierFactory factory)
getAddPrimaryKeyStatement in interface RDBMSAdaptergetAddPrimaryKeyStatement in class DatabaseAdapterpk - An object describing the primary key.factory - Identifier factory
public String getAddForeignKeyStatement(ForeignKey fk,
org.datanucleus.store.mapped.IdentifierFactory factory)
ALTER TABLE FOO ADD CONSTRAINT FOREIGN KEY (BAR, BAZ) REFERENCES ABC (COL1, COL2) CONSTRAINT FOO_FK1 ALTER TABLE FOO ADD FOREIGN KEY (BAR, BAZ) REFERENCES ABC (COL1, COL2)
getAddForeignKeyStatement in interface RDBMSAdaptergetAddForeignKeyStatement in class DatabaseAdapterfk - An object describing the foreign key.factory - Identifier factory
public String getAddCandidateKeyStatement(CandidateKey ck,
org.datanucleus.store.mapped.IdentifierFactory factory)
ALTER TABLE FOO ADD CONSTRAINT FOO_CK UNIQUE (BAZ) ALTER TABLE FOO ADD UNIQUE (BAZ)
getAddCandidateKeyStatement in interface RDBMSAdaptergetAddCandidateKeyStatement in class DatabaseAdapterck - An object describing the candidate key.factory - Identifier factory
public String getDatastoreDateStatement()
getDatastoreDateStatement in interface RDBMSAdaptergetDatastoreDateStatement in class DatabaseAdapterpublic boolean isStatementTimeout(SQLException sqle)
DatabaseAdapter
isStatementTimeout in interface RDBMSAdapterisStatementTimeout in class DatabaseAdaptersqle - the exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||