public abstract class DbModelPostgresql extends DbModelAbstract
Modifier and Type | Class and Description |
---|---|
protected static class |
DbModelPostgresql.DBType |
protected static class |
DbModelPostgresql.DbTypeResolverPostgreSQL |
DbModelAbstract.DbTypeResolver
Modifier and Type | Field and Description |
---|---|
protected Boolean |
useIsValid |
dbTypeResolver
Modifier | Constructor and Description |
---|---|
protected |
DbModelPostgresql()
Create the object and initialize if necessary the driver
|
Modifier and Type | Method and Description |
---|---|
DbType |
getDbType() |
String |
limitRequest(String allfields,
String request,
int nb)
Add a limit on the request to get the "limit" first rows.
|
long |
nextSequence(DbSession dbSession) |
void |
resetSequence(DbSession session,
long newvalue)
Reset the sequence (example)
|
protected String |
validConnectionString() |
closeInternalConnection, currentNumberOfPooledConnections, getDbConnection, getDbTypeResolver, releaseResources, validConnection, validConnectionSelect
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createTables, needUpgradeDb, upgradeDb
protected Boolean useIsValid
protected DbModelPostgresql() throws WaarpDatabaseNoConnectionException
public DbType getDbType()
public void resetSequence(DbSession session, long newvalue) throws WaarpDatabaseNoConnectionException
DbModel
session
- SQL sessionWaarpDatabaseNoConnectionException
public long nextSequence(DbSession dbSession) throws WaarpDatabaseNoConnectionException, WaarpDatabaseSqlException, WaarpDatabaseNoDataException
WaarpDatabaseNoConnectionException
WaarpDatabaseSqlException
WaarpDatabaseNoDataException
protected String validConnectionString()
validConnectionString
in class DbModelAbstract
public String limitRequest(String allfields, String request, int nb)
DbModel
On Oracle: select allfield from (request) where rownnum <= limit
On others: request LIMIT limit
allfields
- string representing the equivalent to "*" in
"select
*" but more precisely as "field1,
field2" in "select field1, field2"Copyright © 2009–2020 Waarp. All rights reserved.