rem stringlengths 0 477k | add stringlengths 0 313k | context stringlengths 6 599k |
|---|---|---|
if ( eof ) throw new EOFException(MessageService.getTextMessage (SQLState.STREAM_EOF)); | public int read() throws IOException { if (dummyBytes != 0) { dummyBytes--; return 0; } int ret = super.read(); if (ret < 0) checkSufficientData(); return ret; } | |
private long getLastPageNumber(BaseContainerHandle handle) throws StandardException | protected long getLastPageNumber(BaseContainerHandle handle) throws StandardException | private long getLastPageNumber(BaseContainerHandle handle) throws StandardException { long retval; synchronized(allocCache) { retval = allocCache.getLastPageNumber(handle, firstAllocPageNumber); } return retval; } |
suite.addTestSuite(MainTest.class); | public static Test suite() { TestSuite suite = new TestSuite("Test for iceClient"); //$JUnit-BEGIN$ suite.addTestSuite(MainTest.class); //$JUnit-END$ return suite; } | |
System.out.println("TESTING READ_ONLY TRANSACTION FOLLOWED BY WRTIABLE TRANSACTION"); | System.out.println("TESTING READ_ONLY TRANSACTION FOLLOWED BY WRITABLE TRANSACTION"); | protected void runTest(String[] args) throws Exception { // Check the returned type of the JDBC Connections. ij.getPropertyArg(args); Connection dmc = ij.startJBMS(); dmc.createStatement().executeUpdate("create table y(i int)"); dmc.createStatement().executeUpdate( "create procedure checkConn2(in d... |
networkServer.start(null); | networkServer.start(new PrintWriter(serverOutput)); | private void startNetworkServer() { String hostName = null; int serverPort; // Determines which host and port to run the network server on // This is based how it is done in the test testSecMec.java String serverName = TestUtil.getHostName(); if (serverName.equals("localhos... |
if (serverOutput != null) { serverOutput.close(); } | private void stopNetworkServer() { try { NetworkServerControl networkServer = new NetworkServerControl(); networkServer.shutdown(); } catch(Exception e) { System.out.println("INFO: Network server shutdown returned: " + e); } } | |
int isolationLevel | int isolationLevel, int maxMemoryPerTable | int getScanArgs(TransactionController tc, MethodBuilder mb, Optimizable innerTable, OptimizablePredicateList storeRestrictionList, OptimizablePredicateList nonStoreRestrictionList, ExpressionClassBuilderInterface acb, int bulkFetch, MethodBuilder resultRowAllocator, int ... |
flowAutoCommitIfNotAutoCommitted(); | statement_.resultSetCommitting(this); | public final void closeX() throws SqlException { if (!openOnClient_) { return; } try { if (openOnServer_) { flowCloseAndAutoCommitIfNotAutoCommitted(); } else { flowAutoCommitIfNotAutoCommitted(); // in case of early close ... |
flowAutoCommitIfLastOpenMultipleResultSetWasJustClosed(); | public final void closeX() throws SqlException { if (!openOnClient_) { return; } try { if (openOnServer_) { flowCloseAndAutoCommitIfNotAutoCommitted(); } else { flowAutoCommitIfNotAutoCommitted(); // in case of early close ... | |
writeCloseAndAutoCommitIfNotAutoCommitted(); | boolean performedAutoCommit = writeCloseAndAutoCommit(); | void flowCloseAndAutoCommitIfNotAutoCommitted() throws SqlException { agent_.beginWriteChain(statement_); writeCloseAndAutoCommitIfNotAutoCommitted(); agent_.flow(statement_); readCloseAndAutoCommitIfNotAutoCommitted(); agent_.endReadChain(); } |
readCloseAndAutoCommitIfNotAutoCommitted(); | readCloseAndAutoCommit(performedAutoCommit); | void flowCloseAndAutoCommitIfNotAutoCommitted() throws SqlException { agent_.beginWriteChain(statement_); writeCloseAndAutoCommitIfNotAutoCommitted(); agent_.flow(statement_); readCloseAndAutoCommitIfNotAutoCommitted(); agent_.endReadChain(); } |
closeX(); | statement_.resultSetCommitting(this); | boolean nextX() throws SqlException { checkForClosedResultSet(); clearWarningsX(); wasNull_ = ResultSet.WAS_NULL_UNSET; // discard all previous updates when moving the cursor resetUpdatedColumns(); // for TYPE_FORWARD_ONLY ResultSet, just call cursor.next() if (resul... |
if (sqlException != null) { | if (sqlException != null) | boolean nextX() throws SqlException { checkForClosedResultSet(); clearWarningsX(); wasNull_ = ResultSet.WAS_NULL_UNSET; // discard all previous updates when moving the cursor resetUpdatedColumns(); // for TYPE_FORWARD_ONLY ResultSet, just call cursor.next() if (resul... |
} | boolean nextX() throws SqlException { checkForClosedResultSet(); clearWarningsX(); wasNull_ = ResultSet.WAS_NULL_UNSET; // discard all previous updates when moving the cursor resetUpdatedColumns(); // for TYPE_FORWARD_ONLY ResultSet, just call cursor.next() if (resul... | |
if (prop == null) { return; } | void updateDataSourceValues(Properties prop) { if (prop.containsKey(propertyKey_user)) { setUser(getUser(prop)); } if (prop.containsKey(propertyKey_securityMechanism)) { setSecurityMechanism(getSecurityMechanism(prop)); } if (prop.containsKey(propertyKey_trac... | |
JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException | JBitSet parentRSNsTables, ResultSetNode childRSN, int [] whichRC) throws StandardException | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
if (crTables.getFirstSetBit() == -1) { return (ValueNode)cr.getClone(); } | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... | |
{ return (ValueNode)cr.getClone(); } if ((childRSN.getReferencedTableMap() != null) && childRSN.getReferencedTableMap().get(cr.getTableNumber())) { return cr; } | return (ColumnReference)cr.getClone(); | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
* reference for childRSN, so go ahead and do it. We get the * target column by column position instead of by name because * it's possible that the name given for the query doesn't match * the name of the actual column we're looking for. Ex. | * reference for childRSN, so go ahead and do it. The way in * which we get the scope target column differs depending on * if childRSN corresponds to the left or right child of the * UNION node. Before explaining that, though, note that it's * not good enough to just search for the target column by * name. The reason... | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
* If we searched for "x" in the childRSN "select i,j from t1" * we wouldn't find it. So we have to look based on position. | * If we were scoping "X1.x" and we searched for "x" in the * childRSN "select i,j from t1" we wouldn't find it. * * It is similarly incorrect to search for the target column * by position (DERBY-1633). This is a bit more subtle, but * if the child to which we're scoping is a subquery whose RCL * does not match the col... | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
rc = childRSN.getResultColumns().getResultColumn(cr.getColumnNumber()); | int [] sourceColPos = new int[] {-1}; ResultSetNode sourceRSN = cr.getSourceResultSet(sourceColPos); if (SanityManager.DEBUG) { SanityManager.ASSERT(sourceRSN != null, "Failed to find source result set when trying to " + "scope column reference '" + cr.getTableName() + "." + cr.getColumnName()); } rc = childRSN.get... | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
"Failed to locate result column when trying to " + | "Failed to locate scope target result column when trying to " + | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
* ColumnReference, then that column reference has all of the info * we need, with one exception: the columnNumber. Depending on our * depth in the tree, the ResultColumn's ColumnReference could be * pointing to a base column in the FromBaseTable. In that case the * ColumnReference will hold the column position as it ... | * ColumnReference, then that column reference has all of the * info we need. | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
* So what does all of that mean? It means that if the ResultColumn * we found has an expression that's a ColumnReference, we can simply * return that ColumnReference IF we set it's columnNumber correctly. * Thankfully the column reference we're trying to scope ("cr") came * from further up the tree and so it knows wha... | * It is, however, possible that the ResultColumn's expression * is NOT a ColumnReference. For example, the expression would * be a constant expression if childRSN represented something * like: | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
* As a final note, we have to be sure we only set the column * reference's column number if the reference points to a base table. * If the reference points to some other ResultSetNode--esp. another * subquery node--then it (the reference) already holds the correct * number with respect to that ResultSetNode and we don'... | * select 1, 1 from t1 * * In this case the expression does not directly reference a * column in the underlying result set and is therefore * "scoped" as far as it can go. This means that the scoped * predicate will not necessarily have column references on * both sides, even though the predicate that we're scoping *... | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
ColumnReference cRef = (ColumnReference)rc.getExpression(); if (cRef.pointsToBaseTable()) cRef.setColumnNumber(cr.getColumnNumber()); | ColumnReference cRef = (ColumnReference) ((ColumnReference)rc.getExpression()).getClone(); cRef.markAsScoped(); | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
/* We can get here if the ResultColumn's expression isn't a * ColumnReference. For example, the expression would be a * constant expression if childRSN represented something like: * * select 1, 1 from t1 * * In this case we just return a clone of the column reference * because it's scoped as far as we can take it. | /* Else just return rc's expression. This means the scoped * predicate will have one operand that is _not_ a column * reference--but that's okay, so long as we account for * that when pushing/remapping the scoped predicate down * the query tree (see esp. "isScopedToSourceResultSet()" * in Predicate.java). | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
return (ValueNode)cr.getClone(); | return rc.getExpression(); | public ValueNode getScopedOperand(int whichSide, JBitSet parentRSNsTables, ResultSetNode childRSN) throws StandardException { ResultColumn rc = null; ColumnReference cr = whichSide == LEFT ? (ColumnReference)leftOperand : (ColumnReference)rightOperand; // The first thing we need to do is see if this Colu... |
case StoredFormatIds.COLUMNS_PERMISSION_FINDER_V01_ID: return new DDColumnPermissionsDependableFinder(fmtId); | public Object getNewInstance() { switch (fmtId) { /* DependableFinders */ case StoredFormatIds.ALIAS_DESCRIPTOR_FINDER_V01_ID: case StoredFormatIds.CONGLOMERATE_DESCRIPTOR_FINDER_V01_ID: case StoredFormatIds.CONSTRAINT_DESCRIPTOR_FINDER_V01_ID: case StoredFormatIds.DEFAULT_DESCRIPTOR_FINDER_V01_ID: ca... | |
stmt.executeUpdate("CREATE TABLE blobTest8TriggerA (a BLOB(300k), b int, crc32 BIGINT)"); stmt.executeUpdate("CREATE TABLE blobTest8TriggerB (a BLOB(200k), b int, crc32 BIGINT)"); | stmt.executeUpdate("CREATE TABLE blobTest8TriggerA (a BLOB(400k), b int, crc32 BIGINT)"); stmt.executeUpdate("CREATE TABLE blobTest8TriggerB (a BLOB(400k), b int, crc32 BIGINT)"); | private static void blobTest8Trigger(Connection conn) { System.out.println(START + "blobTest8Trigger"); try { Statement stmt = conn.createStatement(); stmt.executeUpdate("CREATE TABLE blobTest8TriggerA (a BLOB(300k), b int, crc32 BIGINT)"); stmt.executeUpdate("CREAT... |
do { e.printStackTrace(System.out); e = e.getNextException(); } while (e != null); | private static void blobTest8Trigger(Connection conn) { System.out.println(START + "blobTest8Trigger"); try { Statement stmt = conn.createStatement(); stmt.executeUpdate("CREATE TABLE blobTest8TriggerA (a BLOB(300k), b int, crc32 BIGINT)"); stmt.executeUpdate("CREAT... | |
EncryptData ed = new EncryptData(this); | containerEncrypter = new EncryptData(this); | public void encryptAllContainers(RawTransaction t) throws StandardException { EncryptData ed = new EncryptData(this); // encrypt all the conatiners in the databse ed.encryptAllContainers(t); } |
ed.encryptAllContainers(t); | containerEncrypter.encryptAllContainers(t); | public void encryptAllContainers(RawTransaction t) throws StandardException { EncryptData ed = new EncryptData(this); // encrypt all the conatiners in the databse ed.encryptAllContainers(t); } |
private XAStatementControl(EmbedPooledConnection xaConnection) { | private XAStatementControl(EmbedXAConnection xaConnection) { | private XAStatementControl(EmbedPooledConnection xaConnection) { this.xaConnection = xaConnection; this.realConnection = xaConnection.realConnection; this.applicationConnection = xaConnection.currentConnectionHandle; } |
if (allowOnlySecurityMechanism == INVALID_OR_NOTSET_SECURITYMECHANISM) | if ((allowOnlySecurityMechanism == INVALID_OR_NOTSET_SECURITYMECHANISM) || (allowOnlySecurityMechanism == CodePoint.SECMEC_EUSRIDPWD && !SUPPORTS_EUSRIDPWD)) | private void setSecurityMechanism(String s) throws Exception { allowOnlySecurityMechanism = getSecMecValue(s); if (allowOnlySecurityMechanism == INVALID_OR_NOTSET_SECURITYMECHANISM) consolePropertyMessage("DRDA_InvalidValue.U", new String [] {s, Property... |
int leftToRead = length; int extendedLengthByteCount = prepScalarStream(chained, chainedWithSameCorrelator, writeNullByte, leftToRead); int bytesToRead; | if (netAgent_.netConnection_.getSecurityMechanism() == NetConfiguration.SECMEC_EUSRIDDTA || netAgent_.netConnection_.getSecurityMechanism() == NetConfiguration.SECMEC_EUSRPWDDTA) { writeEncryptedScalarStream(chained, chainedWithSameCorrelator, codePoint, length, in, writeNullByte, parameterIndex); | final void writeScalarStream(boolean chained, boolean chainedWithSameCorrelator, int codePoint, int length, java.io.InputStream in, boolean writeNullByte, ... |
if (writeNullByte) { bytesToRead = Utils.min(leftToRead, DssConstants.MAX_DSS_LEN - 6 - 4 - 1 - extendedLengthByteCount); } else { bytesToRead = Utils.min(leftToRead, DssConstants.MAX_DSS_LEN - 6 - 4 - extendedLengthByteCount); } | }else{ writePlainScalarStream(chained, chainedWithSameCorrelator, codePoint, length, in, writeNullByte, parameterIndex); } | final void writeScalarStream(boolean chained, boolean chainedWithSameCorrelator, int codePoint, int length, java.io.InputStream in, boolean writeNullByte, ... |
if (netAgent_.netConnection_.getSecurityMechanism() == NetConfiguration.SECMEC_EUSRIDDTA || netAgent_.netConnection_.getSecurityMechanism() == NetConfiguration.SECMEC_EUSRPWDDTA) { byte[] lengthAndCodepoint; lengthAndCodepoint = buildLengthAndCodePointForEncryptedLob(codePoint, leftToRead, writeNullByte, extendedLengt... | } | final void writeScalarStream(boolean chained, boolean chainedWithSameCorrelator, int codePoint, int length, java.io.InputStream in, boolean writeNullByte, ... |
spsCompSchemaId = def.getUUID(); } if (SanityManager.DEBUG) { SanityManager.ASSERT(spsCompSchemaId != null, "spsCompSchemaId is null"); | if (def != null) spsCompSchemaId = def.getUUID(); | public void executeConstantAction(Activation activation) throws StandardException { SPSDescriptor whenspsd = null; SPSDescriptor actionspsd; LanguageConnectionContext lcc = activation.getLanguageConnectionContext(); DataDictionary dd = lcc.getDataDictionary(); DependencyManager dm = dd.getDependencyMan... |
Object list = threadContextList.get(); | ThreadLocal tcl = threadContextList; if (tcl == null) { return false; } Object list = tcl.get(); | private boolean addToThreadList(Thread me, ContextManager associateCM) { Object list = threadContextList.get(); if (associateCM == list) return true; if (list == null) { threadContextList.set(associateCM); return true; } java.util.Stack stack; if (list instanceof ContextManager) { ContextManager threads... |
threadContextList.set(associateCM); | tcl.set(associateCM); | private boolean addToThreadList(Thread me, ContextManager associateCM) { Object list = threadContextList.get(); if (associateCM == list) return true; if (list == null) { threadContextList.set(associateCM); return true; } java.util.Stack stack; if (list instanceof ContextManager) { ContextManager threads... |
threadContextList.set(stack); | tcl.set(stack); | private boolean addToThreadList(Thread me, ContextManager associateCM) { Object list = threadContextList.get(); if (associateCM == list) return true; if (list == null) { threadContextList.set(associateCM); return true; } java.util.Stack stack; if (list instanceof ContextManager) { ContextManager threads... |
Object list = threadContextList.get(); | ThreadLocal tcl = threadContextList; if (tcl == null) { return null; } Object list = tcl.get(); | public ContextManager getCurrentContextManager() { Thread me = Thread.currentThread(); Object list = threadContextList.get(); if (list instanceof ContextManager) { ContextManager cm = (ContextManager) list; if (cm.activeThread == me) return cm; return null; } if (list == null) return null; java.uti... |
if (threadContextList.get() != cm) SanityManager.THROWASSERT("resetCurrentContextManager - invalid thread local " + Thread.currentThread() + " - object " + threadContextList.get()); | if (tcl.get() != cm) SanityManager.THROWASSERT("resetCurrentContextManager - invalid thread local " + Thread.currentThread() + " - object " + tcl.get()); | public void resetCurrentContextManager(ContextManager cm) { if (SanityManager.DEBUG) { if (Thread.currentThread() != cm.activeThread) { SanityManager.THROWASSERT("resetCurrentContextManager - mismatch threads - current" + Thread.currentThread() + " - cm's " + cm.activeThread); } if (getCurrentContextManager(... |
java.util.Stack stack = (java.util.Stack) threadContextList.get(); | java.util.Stack stack = (java.util.Stack) tcl.get(); | public void resetCurrentContextManager(ContextManager cm) { if (SanityManager.DEBUG) { if (Thread.currentThread() != cm.activeThread) { SanityManager.THROWASSERT("resetCurrentContextManager - mismatch threads - current" + Thread.currentThread() + " - cm's " + cm.activeThread); } if (getCurrentContextManager(... |
threadContextList.set(nextCM); | tcl.set(nextCM); | public void resetCurrentContextManager(ContextManager cm) { if (SanityManager.DEBUG) { if (Thread.currentThread() != cm.activeThread) { SanityManager.THROWASSERT("resetCurrentContextManager - mismatch threads - current" + Thread.currentThread() + " - cm's " + cm.activeThread); } if (getCurrentContextManager(... |
consolePropertyMessage("DRDA_Ready.I", Integer.toString(portNumber)); | long startTime = System.currentTimeMillis(); consolePropertyMessage("DRDA_Ready.I", new String [] {Integer.toString(portNumber), att_srvclsnm, versionString, CheapDateFormatter.formatDate(startTime)}); | public void blockingStart(PrintWriter consoleWriter) throws Exception { startNetworkServer(); setLogWriter(consoleWriter); cloudscapeLogWriter = Monitor.getStream().getPrintWriter(); if (SanityManager.DEBUG && debugOutput) { memCheck.showmem(); mc = new memCheck(200000); mc.start(); } // Open a ser... |
consolePropertyMessage("DRDA_ShutdownSuccess.I"); | long shutdownTime = System.currentTimeMillis(); consolePropertyMessage("DRDA_ShutdownSuccess.I", new String [] {att_srvclsnm, versionString, CheapDateFormatter.formatDate(shutdownTime)}); | public void blockingStart(PrintWriter consoleWriter) throws Exception { startNetworkServer(); setLogWriter(consoleWriter); cloudscapeLogWriter = Monitor.getStream().getPrintWriter(); if (SanityManager.DEBUG && debugOutput) { memCheck.showmem(); mc = new memCheck(200000); mc.start(); } // Open a ser... |
consolePropertyMessage("DRDA_ShutdownSuccess.I"); | long shutdownTime = System.currentTimeMillis(); consolePropertyMessage("DRDA_ShutdownSuccess.I", new String [] {att_srvclsnm, versionString, CheapDateFormatter.formatDate(shutdownTime)}); | public void executeWork(String args[]) throws Exception { // For convenience just use NetworkServerControlImpls log writer for user messages logWriter = makePrintWriter(System.out); int command = 0; if (args.length > 0) command = findCommand(args); else { consolePropertyMessage("DRDA_NoArgs.U"); } // if... |
versionString = myPVH.getVersionBuildString(false); | private void init() throws Exception { // adjust the application in accordance with derby.ui.locale and derby.ui.codeset langUtil = new LocalizedResource(null,null,DRDA_PROP_MESSAGES); serverInstance = this; //set Server attributes to be used in EXCSAT ProductVersionHolder myPVH = getNetProductVersi... | |
for( Enumeration e = ClassLoader.getSystemResources( "org/apache/derby/modules.properties"); | for( Enumeration e = cl.getResources( "org/apache/derby/modules.properties"); | protected Vector getDefaultImplementations() { Properties moduleList = new Properties(); boolean firstList = true; try { for( Enumeration e = ClassLoader.getSystemResources( "org/apache/derby/modules.properties"); e.hasMoreElements() ;) { URL modulesPropertiesUR... |
RoutinePermsDescriptor key = new RoutinePermsDescriptor( this, authorizationId, (String) null); | RoutinePermsDescriptor key = new RoutinePermsDescriptor( this, authorizationId, (String) null, routineUUID); | public RoutinePermsDescriptor getRoutinePermissions( UUID routineUUID, String authorizationId) throws StandardException { RoutinePermsDescriptor key = new RoutinePermsDescriptor( this, authorizationId, (String) null); return (RoutinePermsDescriptor) getPermissions( key); } // end of getRo... |
networkServerController.start(null); | networkServerController.start(new PrintWriter(serverOutput)); | protected void setUp() throws Exception { TestConfiguration config = TestConfiguration.getCurrent(); if (!config.getJDBCClient().isEmbedded()) { BaseTestCase.println("Starting network server:"); networkServerController = new NetworkServerControl (In... |
serverOutput.close(); | protected void tearDown() throws Exception { if (networkServerController != null) { networkServerController.shutdown(); } } | |
} | case GET_CONTAINER_NAMES_ACTION: { StorageFile seg = storageFactory.newStorageFile( "seg0"); if (seg.exists() && seg.isDirectory()) { return seg.list(); } return null; } } | public final Object run() throws Exception { switch( actionCode) { case BOOT_ACTION: readOnly = storageFactory.isReadOnlyDatabase(); supportsRandomAccess = storageFactory.supportsRandomAccess(); return null; case GET_TEMP_DIRECTORY_ACTION: ... |
con = DriverManager.getConnection( CONFIG.getJDBCUrl() + ";create=true", CONFIG.getUserName(), CONFIG.getUserPassword()); | if (!CONFIG.isSingleLegXA()) { con = DriverManager.getConnection( CONFIG.getJDBCUrl() + ";create=true", CONFIG.getUserName(), CONFIG.getUserPassword()); } else { con = getXADataSource().getXAConnection (CONFIG.getUserName(), CONFIG.getUserPassword()).getConnection(); } | public static Connection getConnection() throws SQLException { Connection con = null; JDBCClient client = CONFIG.getJDBCClient(); if (HAVE_DRIVER) { loadJDBCDriver(client.getJDBCDriverName()); con = DriverManager.getConnection( CONFIG.getJDBCUrl()... |
clientMessageIds.add(SQLState.CANNOT_CLOSE_ACTIVE_XA_CONNECTION); clientMessageIds.add(SQLState.XACT_SAVEPOINT_RELEASE_ROLLBACK_FAIL); | static void initClientMessageIds() { // Add message ids that don't start with XJ here clientMessageIds.add(SQLState.NO_CURRENT_CONNECTION); clientMessageIds.add(SQLState.NOT_IMPLEMENTED); } | |
if (costEstimate == null) { costEstimate = childResult.getCostEstimate(); } | costEstimate = childResult.getFinalCostEstimate(); | private void generateMinion(ExpressionClassBuilder acb, MethodBuilder mb, boolean genChildResultSet) throws StandardException { MethodBuilder userExprFun; ValueNode searchClause = null; ValueNode equijoinClause = null; /* The tableProperties, if non-null, must be correct to get this far. * We si... |
setNull(parameterIndex, java.sql.Types.CLOB); | setNull(parameterIndex, java.sql.Types.LONGVARCHAR); | public void setAsciiStream(int parameterIndex, java.io.InputStream x, long length) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEnt... |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_GENERIC_SCALAR.checkType( paramType ) ){ PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.BIGINT, paramType); } | public void setBigDecimal(int parameterIndex, java.math.BigDecimal x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setBigDecimal", parameterIndex, x); } ... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if ( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_BINARYSTREAM.checkType( paramType ) ){ PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.VARBINARY, paramType ); } | public void setBinaryStream(int parameterIndex, java.io.InputStream x, long length) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.trace... | |
checkTypeForSetBlob(getParameterMetaData().getParameterType(parameterIndex), agent_.logWriter_); | public void setBlob(int parameterIndex, java.sql.Blob x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setBlob", parameterIndex, x); } setBlobX(param... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_GENERIC_SCALAR.checkType(paramType) ) { PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.BOOLEAN, paramType); } | public void setBoolean(int parameterIndex, boolean x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setBoolean", parameterIndex, x); } parameterIndex... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_GENERIC_SCALAR.checkType( paramType ) ){ PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.TINYINT, paramType); } | public void setByte(int parameterIndex, byte x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setByte", parameterIndex, x); } parameterIndex = checkS... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_BYTES.checkType( paramType ) ){ PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.VARBINARY, paramType ); } | public void setBytes(int parameterIndex, byte[] x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setBytes", parameterIndex, x); } setBytesX(parameter... | |
setNull(parameterIndex, java.sql.Types.CLOB); | setNull(parameterIndex, java.sql.Types.LONGVARCHAR); | public void setCharacterStream(int parameterIndex, Reader x) throws SQLException { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setCharacterStream", parameterIndex, x); } try {... |
checkTypeForSetClob(getParameterMetaData().getParameterType(parameterIndex), agent_.logWriter_); | public void setClob(int parameterIndex, java.sql.Clob x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setClob", parameterIndex, x); } setClobX(param... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_DATE.checkType(paramType) ){ PossibleTypes.throw22005Exception(agent_.logWriter_ , java.sql.Types.DATE, paramType); } | public void setDate(int parameterIndex, java.sql.Date x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setDate", parameterIndex, x); } checkForClosed... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_GENERIC_SCALAR.checkType(paramType) ){ PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.DOUBLE, paramType); } | public void setDouble(int parameterIndex, double x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setDouble", parameterIndex, x); } parameterIndex = ... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_GENERIC_SCALAR.checkType(paramType) ){ PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.FLOAT, paramType); } | public void setFloat(int parameterIndex, float x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setFloat", parameterIndex, x); } parameterIndex = che... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_GENERIC_SCALAR.checkType(paramType) ){ PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.INTEGER, paramType); } | public void setInt(int parameterIndex, int x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setInt", parameterIndex, x); } setIntX(parameterIndex, x)... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_GENERIC_SCALAR.checkType(paramType) ){ PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.INTEGER, paramType); } | public void setLong(int parameterIndex, long x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setLong", parameterIndex, x); } parameterIndex = checkS... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex) ; if( ! PossibleTypes.getPossibleTypesForNull( paramType ).checkType( jdbcType )){ PossibleTypes.throw22005Exception(agent_.logWriter_, jdbcType, paramType ); } | public void setNull(int parameterIndex, int jdbcType) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setNull", parameterIndex, jdbcType); } setNullX(p... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_GENERIC_SCALAR.checkType(paramType) ){ PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.SMALLINT, paramType); } | public void setShort(int parameterIndex, short x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setShort", parameterIndex, x); } setShortX(parameterI... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_STRING.checkType( paramType ) ){ PossibleTypes.throw22005Exception(agent_.logWriter_ , java.sql.Types.VARCHAR, paramType); } | public void setString(int parameterIndex, String x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setString", parameterIndex, x); } setStringX(parame... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_TIME.checkType( paramType ) ){ PossibleTypes.throw22005Exception( agent_.logWriter_, java.sql.Types.TIME, paramType ); } | public void setTime(int parameterIndex, java.sql.Time x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setTime", parameterIndex, x); } parameterIndex... | |
final int paramType = getParameterMetaData().getParameterType(parameterIndex); if( ! PossibleTypes.POSSIBLE_TYPES_IN_SET_TIMESTAMP.checkType( paramType ) ) { PossibleTypes.throw22005Exception(agent_.logWriter_, java.sql.Types.TIMESTAMP, paramType); } | public void setTimestamp(int parameterIndex, java.sql.Timestamp x) throws SQLException { try { synchronized (connection_) { if (agent_.loggingEnabled()) { agent_.logWriter_.traceEntry(this, "setTimestamp", parameterIndex, x); } ... | |
String text = getBodyText(); return getConnection().createTextMessage(text); | String value = (text != null) ? text : getBodyText(); return getConnection().createTextMessage(value); | protected Message createMessage() throws Exception { String text = getBodyText(); return getConnection().createTextMessage(text); } |
rs.relative(0); | private void deleteRandomSampleOfNRecords(final ResultSet rs, final Map rows, final Set deletedRows, final int k) throws SQLException { List sampledKeys = createR... | |
rs.relative(0); | private void deleteRandomSampleOfNRecords(final ResultSet rs, final Map rows, final Set deletedRows, final int k) throws SQLException { List sampledKeys = createR... | |
columnList[ SYSCOLPERMS_COLPERMSID - 1] = | columnList[ COLPERMSID_COL_NUM - 1] = | public SystemColumn[] buildColumnList() { if (columnList == null) { columnList = new SystemColumn[ COLUMN_COUNT]; columnList[ SYSCOLPERMS_COLPERMSID - 1] = new SystemColumnImpl( convertIdCase( "COLPERMSID"), SYSCOLPERMS_COLPERMSID, ... |
SYSCOLPERMS_COLPERMSID, | COLPERMSID_COL_NUM, | public SystemColumn[] buildColumnList() { if (columnList == null) { columnList = new SystemColumn[ COLUMN_COUNT]; columnList[ SYSCOLPERMS_COLPERMSID - 1] = new SystemColumnImpl( convertIdCase( "COLPERMSID"), SYSCOLPERMS_COLPERMSID, ... |
String colPermsUUIDString = row.getColumn( SYSCOLPERMS_COLPERMSID).getString(); | String colPermsUUIDString = row.getColumn( COLPERMSID_COL_NUM).getString(); | public TupleDescriptor buildDescriptor(ExecRow row, TupleDescriptor parentTuple, DataDictionary dataDictionary) throws StandardException { if( SanityManager.DEBUG) SanityManager.ASSERT( row.nColumns() == COLUMN_CO... |
case COLPERMSID_INDEX_NUM: row.setColumn(1, getDataValueFactory().getNullChar( (StringDataValue) null)); break; | public ExecIndexRow buildEmptyIndexRow(int indexNumber, RowLocation rowLocation) throws StandardException { ExecIndexRow row = getExecutionFactory().getIndexableRow( indexColumnPositions[indexNumber].length + 1); row.setColumn( row.nColumns(), rowLocatio... | |
case COLPERMSID_INDEX_NUM: row = getExecutionFactory().getIndexableRow( 1); String colPermsUUIDStr = perm.getObjectID().toString(); row.setColumn(1, getDataValueFactory().getCharDataValue( colPermsUUIDStr)); break; | public ExecIndexRow buildIndexKeyRow( int indexNumber, PermissionsDescriptor perm) throws StandardException { ExecIndexRow row = null; switch( indexNumber) { case GRANTEE_TABLE_TYPE_GRANTOR_INDEX_NUM: // RESOLVE We do not ... | |
row.setColumn( SYSCOLPERMS_COLPERMSID, dvf.getCharDataValue(colPermID)); | row.setColumn( COLPERMSID_COL_NUM, dvf.getCharDataValue(colPermID)); | public ExecRow makeRow(TupleDescriptor td, TupleDescriptor parent) throws StandardException { UUID oid; String colPermID = null; DataValueDescriptor grantee = null; DataValueDescriptor grantor = null; String tableID = null; String type = null; FormatableBitSet colu... |
timeLimit = Double.MAX_VALUE; | protected OptimizerImpl(OptimizableList optimizableList, OptimizablePredicateList predicateList, DataDictionary dDictionary, boolean ruleBasedOptimization, boolean noTimeout, boolean useStatistics, int maxMemoryPerTable, JoinStrategy[] joinStrategies, int tableLockThreshold, ... | |
timeExceeded = (currentTime - timeOptimizationStarted) > bestCost.getEstimatedCost(); | timeExceeded = (currentTime - timeOptimizationStarted) > timeLimit; | public boolean getNextPermutation() throws StandardException { /* Don't get any permutations if there is nothing to optimize */ if (numOptimizables < 1) { if (optimizerTrace) { trace(NO_TABLES, 0, 0, 0.0, null); } return false; } /* Make sure that all Optimizables init their access paths. * (They w... |
protected void prepForNextRound() | public void prepForNextRound() | protected void prepForNextRound() { // We initialize reloadBestPlan to false so that if we end up // pulling an Optimizable before we find a best join order // (which can happen if there is no valid join order for this // round) we won't inadvertently reload the best plans based // on some previous round. reload... |
bestCost = getNewCostEstimate( Double.MAX_VALUE, Double.MAX_VALUE, Double.MAX_VALUE); | protected void prepForNextRound() { // We initialize reloadBestPlan to false so that if we end up // pulling an Optimizable before we find a best join order // (which can happen if there is no valid join order for this // round) we won't inadvertently reload the best plans based // on some previous round. reload... | |
if (bestCost.getEstimatedCost() < timeLimit) timeLimit = bestCost.getEstimatedCost(); | private void rememberBestCost(CostEstimate currentCost, int planType) throws StandardException { foundABestPlan = true; if (optimizerTrace) { trace(CHEAPEST_PLAN_SO_FAR, 0, 0, 0.0, null); trace(PLAN_TYPE, planType, 0, 0.0, null); trace(COST_OF_CHEAPEST_PLAN_SO_FAR, 0, 0, 0.0, null); } /* Remember the curre... | |
case Types.DATE: return 10; | public static int getPrecision(DataTypeDescriptor dtd) { int typeId = dtd.getTypeId().getJDBCTypeId(); switch ( typeId ) { case Types.CHAR: // CHAR et alia return their # characters... case Types.VARCHAR: case Types.LONGVARCHAR: case Types.CLOB: case Types.BINARY: // BINARY types return their # bytes... ... | |
ExceptionUtil.getSeverityFromIdentifier(msgid.msgid)); if ( cause != null ) { this.setThrowable(cause); } | ExceptionUtil.getSeverityFromIdentifier(msgid.msgid)); | public SqlException(LogWriter logwriter, ClientMessageId msgid, Object[] args, Throwable cause) { this( logwriter, getMessageUtil().getCompleteMessage( msgid.msgid, args), ExceptionUtil.getSQLStateFromIdentifier(msgid.msgid), ... |
ArrayList<String> answers; | Collection answers; | public void addAnswerToSession(HttpServletRequest request){ HttpSession session = request.getSession(); String answer = request.getParameter("answer"); ArrayList<String> answers; if(session.getAttribute("answers")==null) answers = new ArrayList<String>(); else answers = (ArrayList<String>) session.getAttrib... |
else answers = (ArrayList<String>) session.getAttribute("answers"); | else { Object obj = session.getAttribute("answers"); if(obj instanceof PersistentList) answers = (PersistentList) obj; else answers = (ArrayList<String>) obj; } | public void addAnswerToSession(HttpServletRequest request){ HttpSession session = request.getSession(); String answer = request.getParameter("answer"); ArrayList<String> answers; if(session.getAttribute("answers")==null) answers = new ArrayList<String>(); else answers = (ArrayList<String>) session.getAttrib... |
ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); | Object obj = session.getAttribute("answers"); ArrayList<String> answers = null; if(obj instanceof PersistentList){ Iterator iter = ((PersistentList) obj).iterator(); answers = new ArrayList<String>(); while(iter.hasNext()){ answers.add((String) iter.next()); } } else answers = (ArrayList<String>) session.getAttribute("... | public void addCheckBoxQuestionToSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String questionText = request.getParamet... |
else columns = (ArrayList<String>) session.getAttribute("columns"); | else { Object obj = session.getAttribute("columns"); if(obj instanceof PersistentList){ PersistentList pe = (PersistentList) obj; Iterator iter = pe.iterator(); columns = new ArrayList<String>(); while(iter.hasNext()){ columns.add((String) iter.next()); } } else columns = (ArrayList<String>) session.getAttribute("colum... | public void addColumnToSession(HttpServletRequest request){ HttpSession session = request.getSession(); String column = request.getParameter("column"); ArrayList<String> columns; if(session.getAttribute("columns")==null) columns = new ArrayList<String>(); else columns = (ArrayList<String>) session.getAttribut... |
ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); ArrayList<String> columns = (ArrayList<String>) session.getAttribute("columns"); | Object obj = session.getAttribute("answers"); ArrayList<String> answers = null; if(obj instanceof PersistentList){ Iterator iter = ((PersistentList) obj).iterator(); answers = new ArrayList<String>(); while(iter.hasNext()){ answers.add((String) iter.next()); } } else answers = (ArrayList<String>) session.getAttribute("... | public void addMatrixQuestionToSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String questionText = request.getParameter... |
ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); | Object obj = session.getAttribute("answers"); ArrayList<String> answers = null; if(obj instanceof PersistentList){ Iterator iter = ((PersistentList) obj).iterator(); answers = new ArrayList<String>(); while(iter.hasNext()){ answers.add((String) iter.next()); } } else answers = (ArrayList<String>) session.getAttribute("... | public void addNumericQuestionToSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String validationType = request.getParamete... |
question.setValidationType(validationType); | public void addNumericQuestionToSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String validationType = request.getParamete... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.