public class NGKDbNameIndex extends DbNameIndex
DbNameIndex but does not make use of the
Statement.RETURN_GENERATED_KEYS feature as it might not be provided
by the underlying database (e.g. oracle).conHelper, indexSelectSQL, nameInsertSQL, nameSelectSQL| Constructor and Description |
|---|
NGKDbNameIndex(ConnectionHelper conHelper,
String schemaObjectPrefix)
Creates a new index that is stored in a db.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
init(String schemaObjectPrefix)
Inits this index and prepares the statements.
|
protected int |
insertString(String string)
Inserts a string into the database and returns the new index.
|
close, getIndex, getString, indexToString, stringToIndexpublic NGKDbNameIndex(ConnectionHelper conHelper, String schemaObjectPrefix) throws SQLException
conHelper - the ConnectionHelperschemaObjectPrefix - the prefix for table namesSQLException - if the statements cannot be prepared.protected void init(String schemaObjectPrefix) throws SQLException
init in class DbNameIndexschemaObjectPrefix - the prefix for table namesSQLException - if the statements cannot be prepared.protected int insertString(String string)
Instead of using the Statement.RETURN_GENERATED_KEYS feature, the
newly inserted index is retrieved by a 2nd select statement.
insertString in class DbNameIndexstring - the string to insertCopyright © 2004-2020 The Apache Software Foundation. All Rights Reserved.