|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.openanzo.server.repository.rdb.sql.InsertStatementsRdbWrapper
public class InsertStatementsRdbWrapper
InsertStatementsRdbWrapper provides wrappers around SQL queries and transforms ResultSets into java objects
| Nested Class Summary | |
|---|---|
static class |
InsertStatementsRdbWrapper.BatchCreateIdTable
Batch operation for adding parameters to the CreateIdTable prepared statement |
static class |
InsertStatementsRdbWrapper.BatchDeleteTempStatements
Batch operation for adding parameters to the DeleteTempStatements prepared statement |
static class |
InsertStatementsRdbWrapper.BatchDropIdTable
Batch operation for adding parameters to the DropIdTable prepared statement |
static class |
InsertStatementsRdbWrapper.BatchInsertBatchRequestId
Batch operation for adding parameters to the InsertBatchRequestId prepared statement |
static class |
InsertStatementsRdbWrapper.BatchInsertTempStatement
Batch operation for adding parameters to the InsertTempStatement prepared statement |
static class |
InsertStatementsRdbWrapper.BatchSelectTempIdCount
Batch operation for adding parameters to the SelectTempIdCount prepared statement |
static interface |
InsertStatementsRdbWrapper.InsertTempStatementParams
Interface for managing the parameters to the insertTempStatement prepared statement. |
static class |
InsertStatementsRdbWrapper.InsertTempStatementParamsImpl
Default implementation of InsertTempStatementParams |
static interface |
InsertStatementsRdbWrapper.SelectInsertStatementsResult
Interface for holding the results of the selectInsertStatements prepared statement. |
static class |
InsertStatementsRdbWrapper.SelectInsertStatementsResultImpl
Default implementation of SelectInsertStatementsResult |
| Field Summary | |
|---|---|
static java.lang.String |
commitInsertStatements
Constant "commitInsertStatements" used to reference prepared statement InsertStatements.commitInsertStatements
INSERT INTO STATEMENTS(NAMEDGRAPHID,SUBJ,PROP,OBJ,HSTART) SELECT ${a}STMTS_TMP.NAMEDGRAPHID, ${a}STMTS_TMP.SUBJ, ${a}STMTS_TMP.PROP, ${a}STMTS_TMP.OBJ, ${a}STMTS_TMP.MODIFIED FROM ${a}STMTS_TMP WHERE ${a}STMTS_TMP.OPERATION=1
|
static java.lang.String |
commitRemoveStatements
Constant "commitRemoveStatements" used to reference prepared statement InsertStatements.commitRemoveStatements
UPDATE STATEMENTS SET HEND=? WHERE ID IN( SELECT DISTINCT S.ID FROM ${a}STMTS_TMP ST,STATEMENTS S WHERE ST.OPERATION=0 AND ST.SUBJ=S.SUBJ AND ST.PROP=S.PROP AND ST.OBJ=S.OBJ AND ST.NAMEDGRAPHID=S.NAMEDGRAPHID AND S.HEND IS NULL)
|
static java.lang.String |
countInsertStatements
Constant "countInsertStatements" used to reference prepared statement InsertStatements.countInsertStatements
SELECT COUNT(*) FROM ${a}STMTS_TMP WHERE OPERATION=1
|
static java.lang.String |
countRemoveStatements
Constant "countRemoveStatements" used to reference prepared statement InsertStatements.countRemoveStatements
SELECT COUNT(*) FROM ${a}STMTS_TMP WHERE OPERATION=0
|
static java.lang.String |
createIdTable
Constant "createIdTable" used to reference prepared statement InsertStatements.createIdTable
DECLARE GLOBAL TEMPORARY TABLE IDS_TMP ( ID Long NOT NULL ) ON COMMIT DELETE ROWS NOT LOGGED ON ROLLBACK DELETE ROWS WITH REPLACE IN USR_TBSP;
|
static java.lang.String |
deleteTempStatements
Constant "deleteTempStatements" used to reference prepared statement InsertStatements.deleteTempStatements
DELETE FROM ${a}STMTS_TMP WHERE OPERATION IS NOT NULL
|
static java.lang.String |
dropIdTable
Constant "dropIdTable" used to reference prepared statement InsertStatements.dropIdTable
DROP TABLE ${a}IDS_TMP;
|
static java.lang.String |
getMax
Constant "getMax" used to reference prepared statement InsertStatements.getMax
SELECT MAX(ID) FROM STATEMENT
|
static java.lang.String |
getTempTablespaceDefined
Constant "getTempTablespaceDefined" used to reference prepared statement InsertStatements.getTempTablespaceDefined
SELECT COUNT(*) FROM SYSIBM.SYSTABLESPACES WHERE TBSPACE='USR_TBSP'
|
static java.lang.String |
insertBatchRequestId
Constant "insertBatchRequestId" used to reference prepared statement InsertStatements.insertBatchRequestId
INSERT INTO ${a}IDS_TMP (ID) VALUES (?);
|
static java.lang.String |
insertTempStatement
Constant "insertTempStatement" used to reference prepared statement InsertStatements.insertTempStatement
INSERT INTO ${a}STMTS_TMP(OPERATION,NAMEDGRAPHID,SUBJ,PROP,OBJ,MODIFIED) VALUES(?,?,?,?,?,?)
|
static java.lang.String |
purgeInsertStatements
Constant "purgeInsertStatements" used to reference prepared statement InsertStatements.purgeInsertStatements
DELETE FROM ${a}STMTS_TMP WHERE ${a}STMTS_TMP.OPERATION=1 AND EXISTS (SELECT S.NAMEDGRAPHID FROM STATEMENTS S WHERE S.NAMEDGRAPHID=${a}STMTS_TMP.NAMEDGRAPHID AND S.SUBJ=${a}STMTS_TMP.SUBJ AND S.PROP=${a}STMTS_TMP.PROP AND S.OBJ=${a}STMTS_TMP.OBJ AND S.HEND IS NULL)
|
static java.lang.String |
purgeRemveStatements
Constant "purgeRemveStatements" used to reference prepared statement InsertStatements.purgeRemveStatements
DELETE FROM ${a}STMTS_TMP WHERE ${a}STMTS_TMP.OPERATION=0 AND NOT EXISTS (SELECT S.NAMEDGRAPHID FROM STATEMENTS S WHERE S.NAMEDGRAPHID=${a}STMTS_TMP.NAMEDGRAPHID AND S.SUBJ=${a}STMTS_TMP.SUBJ AND S.PROP=${a}STMTS_TMP.PROP AND S.OBJ=${a}STMTS_TMP.OBJ AND S.HEND IS NULL)
|
static java.lang.String |
selectInsertStatements
Constant "selectInsertStatements" used to reference prepared statement InsertStatements.selectInsertStatements
SELECT ST.OPERATION, ST.NAMEDGRAPHID, ST.SUBJ, ST.PROP, ST.OBJ FROM ${a}STMTS_TMP ST
|
static java.lang.String |
selectTempIdCount
Constant "selectTempIdCount" used to reference prepared statement InsertStatements.selectTempIdCount
SELECT COUNT(*) FROM ${a}IDS_TMP
|
| Constructor Summary | |
|---|---|
InsertStatementsRdbWrapper()
|
|
| Method Summary | |
|---|---|
static int |
commitInsertStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
Runs the commitInsertStatements prepared statement. |
static int |
commitRemoveStatements(PreparedStatementCache sqlCache,
java.lang.Long hstart,
java.lang.String sessionPrefix)
Runs the commitRemoveStatements prepared statement. |
static java.lang.Long |
countInsertStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
Runs the countInsertStatements prepared statement. |
static java.lang.Long |
countRemoveStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
Runs the countRemoveStatements prepared statement. |
static void |
createIdTable(PreparedStatementCache sqlCache)
Runs the createIdTable prepared statement. |
static void |
deleteTempStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
Runs the deleteTempStatements prepared statement. |
static void |
dropIdTable(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
Runs the dropIdTable prepared statement. |
static java.lang.Integer |
getMax(PreparedStatementCache sqlCache)
Runs the getMax prepared statement. |
static java.lang.Long |
getTempTablespaceDefined(PreparedStatementCache sqlCache)
Runs the getTempTablespaceDefined prepared statement. |
static void |
insertBatchRequestId(PreparedStatementCache sqlCache,
long id,
java.lang.String sessionPrefix)
Runs the insertBatchRequestId prepared statement. |
static void |
insertTempStatement(PreparedStatementCache sqlCache,
InsertStatementsRdbWrapper.InsertTempStatementParams params,
java.lang.String sessionPrefix)
Runs the insertTempStatement prepared statement. |
static void |
insertTempStatement(PreparedStatementCache sqlCache,
int operation,
long graphid,
long subj,
long prop,
long obj,
java.lang.Long modified,
java.lang.String sessionPrefix)
Runs the insertTempStatement prepared statement. |
static void |
prepareCommitInsertStatements(java.sql.PreparedStatement ps)
Sets the input parameters for the commitInsertStatements prepared statement. |
static void |
prepareCommitRemoveStatements(java.sql.PreparedStatement ps,
java.lang.Long hstart)
Sets the input parameters for the commitRemoveStatements prepared statement. |
static void |
prepareCountInsertStatements(java.sql.PreparedStatement ps)
Sets the input parameters for the countInsertStatements prepared statement. |
static void |
prepareCountRemoveStatements(java.sql.PreparedStatement ps)
Sets the input parameters for the countRemoveStatements prepared statement. |
static void |
prepareCreateIdTable(java.sql.PreparedStatement ps)
Sets the input parameters for the createIdTable prepared statement. |
static void |
prepareDeleteTempStatements(java.sql.PreparedStatement ps)
Sets the input parameters for the deleteTempStatements prepared statement. |
static void |
prepareDropIdTable(java.sql.PreparedStatement ps)
Sets the input parameters for the dropIdTable prepared statement. |
static void |
prepareGetMax(java.sql.PreparedStatement ps)
Sets the input parameters for the getMax prepared statement. |
static void |
prepareGetTempTablespaceDefined(java.sql.PreparedStatement ps)
Sets the input parameters for the getTempTablespaceDefined prepared statement. |
static void |
prepareInsertBatchRequestId(java.sql.PreparedStatement ps,
long id)
Sets the input parameters for the insertBatchRequestId prepared statement. |
static void |
prepareInsertTempStatement(java.sql.PreparedStatement ps,
int operation,
long graphid,
long subj,
long prop,
long obj,
java.lang.Long modified)
Sets the input parameters for the insertTempStatement prepared statement. |
static void |
preparePurgeInsertStatements(java.sql.PreparedStatement ps)
Sets the input parameters for the purgeInsertStatements prepared statement. |
static void |
preparePurgeRemveStatements(java.sql.PreparedStatement ps)
Sets the input parameters for the purgeRemveStatements prepared statement. |
static void |
prepareSelectInsertStatements(java.sql.PreparedStatement ps)
Sets the input parameters for the selectInsertStatements prepared statement. |
static void |
prepareSelectTempIdCount(java.sql.PreparedStatement ps)
Sets the input parameters for the selectTempIdCount prepared statement. |
static int |
purgeInsertStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
Runs the purgeInsertStatements prepared statement. |
static int |
purgeRemveStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
Runs the purgeRemveStatements prepared statement. |
static ClosableIterator<InsertStatementsRdbWrapper.SelectInsertStatementsResult> |
selectInsertStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
Runs the selectInsertStatements prepared statement with the default transformer. |
static ClosableIterator<InsertStatementsRdbWrapper.SelectInsertStatementsResult> |
selectInsertStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix,
Transformer<InsertStatementsRdbWrapper.SelectInsertStatementsResult> transform)
Runs the selectInsertStatements prepared statement. |
static void |
selectTempIdCount(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
Runs the selectTempIdCount prepared statement. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String getTempTablespaceDefined
SELECT COUNT(*) FROM SYSIBM.SYSTABLESPACES WHERE TBSPACE='USR_TBSP'
public static final java.lang.String insertTempStatement
INSERT INTO ${a}STMTS_TMP(OPERATION,NAMEDGRAPHID,SUBJ,PROP,OBJ,MODIFIED) VALUES(?,?,?,?,?,?)
public static final java.lang.String deleteTempStatements
DELETE FROM ${a}STMTS_TMP WHERE OPERATION IS NOT NULL
public static final java.lang.String selectInsertStatements
SELECT ST.OPERATION, ST.NAMEDGRAPHID, ST.SUBJ, ST.PROP, ST.OBJ FROM ${a}STMTS_TMP ST
public static final java.lang.String purgeInsertStatements
DELETE FROM ${a}STMTS_TMP WHERE ${a}STMTS_TMP.OPERATION=1 AND EXISTS (SELECT S.NAMEDGRAPHID FROM STATEMENTS S WHERE S.NAMEDGRAPHID=${a}STMTS_TMP.NAMEDGRAPHID AND S.SUBJ=${a}STMTS_TMP.SUBJ AND S.PROP=${a}STMTS_TMP.PROP AND S.OBJ=${a}STMTS_TMP.OBJ AND S.HEND IS NULL)
public static final java.lang.String purgeRemveStatements
DELETE FROM ${a}STMTS_TMP WHERE ${a}STMTS_TMP.OPERATION=0 AND NOT EXISTS (SELECT S.NAMEDGRAPHID FROM STATEMENTS S WHERE S.NAMEDGRAPHID=${a}STMTS_TMP.NAMEDGRAPHID AND S.SUBJ=${a}STMTS_TMP.SUBJ AND S.PROP=${a}STMTS_TMP.PROP AND S.OBJ=${a}STMTS_TMP.OBJ AND S.HEND IS NULL)
public static final java.lang.String countInsertStatements
SELECT COUNT(*) FROM ${a}STMTS_TMP WHERE OPERATION=1
public static final java.lang.String countRemoveStatements
SELECT COUNT(*) FROM ${a}STMTS_TMP WHERE OPERATION=0
public static final java.lang.String commitInsertStatements
INSERT INTO STATEMENTS(NAMEDGRAPHID,SUBJ,PROP,OBJ,HSTART) SELECT ${a}STMTS_TMP.NAMEDGRAPHID, ${a}STMTS_TMP.SUBJ, ${a}STMTS_TMP.PROP, ${a}STMTS_TMP.OBJ, ${a}STMTS_TMP.MODIFIED FROM ${a}STMTS_TMP WHERE ${a}STMTS_TMP.OPERATION=1
public static final java.lang.String commitRemoveStatements
UPDATE STATEMENTS SET HEND=? WHERE ID IN( SELECT DISTINCT S.ID FROM ${a}STMTS_TMP ST,STATEMENTS S WHERE ST.OPERATION=0 AND ST.SUBJ=S.SUBJ AND ST.PROP=S.PROP AND ST.OBJ=S.OBJ AND ST.NAMEDGRAPHID=S.NAMEDGRAPHID AND S.HEND IS NULL)
public static final java.lang.String getMax
SELECT MAX(ID) FROM STATEMENT
public static final java.lang.String createIdTable
DECLARE GLOBAL TEMPORARY TABLE IDS_TMP ( ID Long NOT NULL ) ON COMMIT DELETE ROWS NOT LOGGED ON ROLLBACK DELETE ROWS WITH REPLACE IN USR_TBSP;
public static final java.lang.String dropIdTable
DROP TABLE ${a}IDS_TMP;
public static final java.lang.String insertBatchRequestId
INSERT INTO ${a}IDS_TMP (ID) VALUES (?);
public static final java.lang.String selectTempIdCount
SELECT COUNT(*) FROM ${a}IDS_TMP
| Constructor Detail |
|---|
public InsertStatementsRdbWrapper()
| Method Detail |
|---|
public static java.lang.Long getTempTablespaceDefined(PreparedStatementCache sqlCache)
throws AnzoException,
java.sql.SQLException
SELECT COUNT(*) FROM SYSIBM.SYSTABLESPACES WHERE TBSPACE='USR_TBSP'
sqlCache - factory and cache of PreparedStatments
AnzoException
java.sql.SQLException
public static void prepareGetTempTablespaceDefined(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static void insertTempStatement(PreparedStatementCache sqlCache,
InsertStatementsRdbWrapper.InsertTempStatementParams params,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
INSERT INTO ${a}STMTS_TMP(OPERATION,NAMEDGRAPHID,SUBJ,PROP,OBJ,MODIFIED) VALUES(?,?,?,?,?,?)
sqlCache - factory and cache of PreparedStatmentsparams - InsertTempStatementParams input InterfacesessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void insertTempStatement(PreparedStatementCache sqlCache,
int operation,
long graphid,
long subj,
long prop,
long obj,
java.lang.Long modified,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
INSERT INTO ${a}STMTS_TMP(OPERATION,NAMEDGRAPHID,SUBJ,PROP,OBJ,MODIFIED) VALUES(?,?,?,?,?,?)
sqlCache - factory and cache of PreparedStatmentsoperation - template parametergraphid - template parametersubj - template parameterprop - template parameterobj - template parametermodified - template parametersessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void prepareInsertTempStatement(java.sql.PreparedStatement ps,
int operation,
long graphid,
long subj,
long prop,
long obj,
java.lang.Long modified)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are setoperation - template parametergraphid - template parametersubj - template parameterprop - template parameterobj - template parametermodified - template parameter
java.sql.SQLException
public static void deleteTempStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
DELETE FROM ${a}STMTS_TMP WHERE OPERATION IS NOT NULL
sqlCache - factory and cache of PreparedStatmentssessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void prepareDeleteTempStatements(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static ClosableIterator<InsertStatementsRdbWrapper.SelectInsertStatementsResult> selectInsertStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
SELECT ST.OPERATION, ST.NAMEDGRAPHID, ST.SUBJ, ST.PROP, ST.OBJ FROM ${a}STMTS_TMP ST
sqlCache - factory and cache of PreparedStatmentssessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static ClosableIterator<InsertStatementsRdbWrapper.SelectInsertStatementsResult> selectInsertStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix,
Transformer<InsertStatementsRdbWrapper.SelectInsertStatementsResult> transform)
throws AnzoException,
java.sql.SQLException
SELECT ST.OPERATION, ST.NAMEDGRAPHID, ST.SUBJ, ST.PROP, ST.OBJ FROM ${a}STMTS_TMP ST
sqlCache - factory and cache of PreparedStatmentssessionPrefix - template parametertransform - org.openanzo.jdbc.utils.TransformerAnzoException
java.sql.SQLException
public static void prepareSelectInsertStatements(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static int purgeInsertStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
DELETE FROM ${a}STMTS_TMP WHERE ${a}STMTS_TMP.OPERATION=1 AND EXISTS (SELECT S.NAMEDGRAPHID FROM STATEMENTS S WHERE S.NAMEDGRAPHID=${a}STMTS_TMP.NAMEDGRAPHID AND S.SUBJ=${a}STMTS_TMP.SUBJ AND S.PROP=${a}STMTS_TMP.PROP AND S.OBJ=${a}STMTS_TMP.OBJ AND S.HEND IS NULL)
sqlCache - factory and cache of PreparedStatmentssessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void preparePurgeInsertStatements(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static int purgeRemveStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
DELETE FROM ${a}STMTS_TMP WHERE ${a}STMTS_TMP.OPERATION=0 AND NOT EXISTS (SELECT S.NAMEDGRAPHID FROM STATEMENTS S WHERE S.NAMEDGRAPHID=${a}STMTS_TMP.NAMEDGRAPHID AND S.SUBJ=${a}STMTS_TMP.SUBJ AND S.PROP=${a}STMTS_TMP.PROP AND S.OBJ=${a}STMTS_TMP.OBJ AND S.HEND IS NULL)
sqlCache - factory and cache of PreparedStatmentssessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void preparePurgeRemveStatements(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static java.lang.Long countInsertStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
SELECT COUNT(*) FROM ${a}STMTS_TMP WHERE OPERATION=1
sqlCache - factory and cache of PreparedStatmentssessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void prepareCountInsertStatements(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static java.lang.Long countRemoveStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
SELECT COUNT(*) FROM ${a}STMTS_TMP WHERE OPERATION=0
sqlCache - factory and cache of PreparedStatmentssessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void prepareCountRemoveStatements(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static int commitInsertStatements(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
INSERT INTO STATEMENTS(NAMEDGRAPHID,SUBJ,PROP,OBJ,HSTART) SELECT ${a}STMTS_TMP.NAMEDGRAPHID, ${a}STMTS_TMP.SUBJ, ${a}STMTS_TMP.PROP, ${a}STMTS_TMP.OBJ, ${a}STMTS_TMP.MODIFIED FROM ${a}STMTS_TMP WHERE ${a}STMTS_TMP.OPERATION=1
sqlCache - factory and cache of PreparedStatmentssessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void prepareCommitInsertStatements(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static int commitRemoveStatements(PreparedStatementCache sqlCache,
java.lang.Long hstart,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
UPDATE STATEMENTS SET HEND=? WHERE ID IN( SELECT DISTINCT S.ID FROM ${a}STMTS_TMP ST,STATEMENTS S WHERE ST.OPERATION=0 AND ST.SUBJ=S.SUBJ AND ST.PROP=S.PROP AND ST.OBJ=S.OBJ AND ST.NAMEDGRAPHID=S.NAMEDGRAPHID AND S.HEND IS NULL)
sqlCache - factory and cache of PreparedStatmentshstart - template parametersessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void prepareCommitRemoveStatements(java.sql.PreparedStatement ps,
java.lang.Long hstart)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are sethstart - template parameter
java.sql.SQLException
public static java.lang.Integer getMax(PreparedStatementCache sqlCache)
throws AnzoException,
java.sql.SQLException
SELECT MAX(ID) FROM STATEMENT
sqlCache - factory and cache of PreparedStatments
AnzoException
java.sql.SQLException
public static void prepareGetMax(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static void createIdTable(PreparedStatementCache sqlCache)
throws AnzoException,
java.sql.SQLException
DECLARE GLOBAL TEMPORARY TABLE IDS_TMP ( ID Long NOT NULL ) ON COMMIT DELETE ROWS NOT LOGGED ON ROLLBACK DELETE ROWS WITH REPLACE IN USR_TBSP;
sqlCache - factory and cache of PreparedStatments
AnzoException
java.sql.SQLException
public static void prepareCreateIdTable(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static void dropIdTable(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
DROP TABLE ${a}IDS_TMP;
sqlCache - factory and cache of PreparedStatmentssessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void prepareDropIdTable(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
public static void insertBatchRequestId(PreparedStatementCache sqlCache,
long id,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
INSERT INTO ${a}IDS_TMP (ID) VALUES (?);
sqlCache - factory and cache of PreparedStatmentsid - template parametersessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void prepareInsertBatchRequestId(java.sql.PreparedStatement ps,
long id)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are setid - template parameter
java.sql.SQLException
public static void selectTempIdCount(PreparedStatementCache sqlCache,
java.lang.String sessionPrefix)
throws AnzoException,
java.sql.SQLException
SELECT COUNT(*) FROM ${a}IDS_TMP
sqlCache - factory and cache of PreparedStatmentssessionPrefix - template parameter
AnzoException
java.sql.SQLException
public static void prepareSelectTempIdCount(java.sql.PreparedStatement ps)
throws java.sql.SQLException
ps - PreparedStatement to whose parameters are set
java.sql.SQLException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||