Package org.apache.derby.iapi.sql.conn

Examples of org.apache.derby.iapi.sql.conn.LanguageConnectionContext


    synchronized (getConnectionSynchronization())
    {
            setupContextStack();
      try
      {
                LanguageConnectionContext lcc = getLanguageConnection();
                lcc.xaRollback();
                InterruptStatus.restoreIntrFlagIfSeen(lcc);
      } catch (StandardException t)
      {
        throw handleException(t);
      }
View Full Code Here


    public String toString()
    {
        if ( connString == null )
        {
           
            LanguageConnectionContext lcc = getLanguageConnection();

            connString =
              this.getClass().getName() + "@" + this.hashCode() + " " +
                lcc.xidStr +                 
                    lcc.getTransactionExecute().getTransactionIdString() +
                    "), " +
                lcc.lccStr +
                    Integer.toString(lcc.getInstanceNumber()) + "), " +
                lcc.dbnameStr + lcc.getDbname() + "), " +
                lcc.drdaStr + lcc.getDrdaID() + ") ";
        }      
       
        return connString;
    }
View Full Code Here

      // need to invalidate the statement
      if (!isValid || (inUseCount != 0))
        return;

      ContextManager cm = ContextService.getFactory().getCurrentContextManager();
      LanguageConnectionContext lcc =
        (LanguageConnectionContext)
        (cm.getContext(LanguageConnectionContext.CONTEXT_ID));

      // invalidate any prepared statements that
      // depended on this statement (including this one)
View Full Code Here

    synchronized(getConnectionSynchronization())
    {
            setupContextStack();
      try {
                LanguageConnectionContext lcc = getLanguageConnection();
                return lcc.getCurrentSchemaName();
      } finally {
        restoreContextStack();
      }
    }
  }
View Full Code Here

    cm.setLocaleFinder(this);
    pushDbContext(cm);

    // push a database shutdown context
    // we also need to push a language connection context.
    LanguageConnectionContext lctx = lcf.newLanguageConnectionContext(cm, tc, lf, this, user, drdaID, dbname);

    // push the context that defines our class factory
    pushClassFactoryContext(cm, lcf.getClassFactory());

    // we also need to push an execution context.
    ExecutionFactory ef = lcf.getExecutionFactory();

    ef.newExecutionContext(cm);
    //
    //Initialize our language connection context. Note: This is
    //a bit of a hack. Unfortunately, we can't initialize this
    //when we push it. We first must push a few more contexts.
    lctx.initialize();   

    // Need to commit this to release locks gotten in initialize. 
    // Commit it but make sure transaction not have any updates.
    lctx.internalCommitNoSync(
      TransactionController.RELEASE_LOCKS |
      TransactionController.READONLY_TRANSACTION_INITIALIZATION);

    return lctx;
View Full Code Here

   */
  public void dropAllJDBCMetaDataSPSes() throws SQLException
  {
    try
    {
      LanguageConnectionContext lcc = ConnectionUtil.getCurrentLCC();

      DataDictionary dd = lcc.getDataDictionary();

      TransactionController tc = lcc.getTransactionExecute();

      /*
      ** Inform the data dictionary we are going
      ** to perform some DDL
      */
 
View Full Code Here

       been initialized and therefore can give a NullPointerException
     */
    DataDictionary dd = super.getDataDictionary();
     if (dd == null)
     {
        LanguageConnectionContext lcc = (LanguageConnectionContext)
        ContextService.getContext(LanguageConnectionContext.CONTEXT_ID);
        dd = lcc.getDataDictionary();
      setDataDictionary(dd);
      }
    return dd;
   }
View Full Code Here

        resultSet = null;
      }

      closed = true;

      LanguageConnectionContext lcc = getLanguageConnectionContext();

      lcc.removeActivation(this);
      if (preStmt != null) {
        preStmt.finish(lcc);
        preStmt = null;
      }
View Full Code Here

    ExecPreparedStatement ps = getPreparedStatement();
    if (ps == null)
      return;
     
    LanguageConnectionContext lcc = getLanguageConnectionContext();

    CursorActivation cursorActivation = lcc.lookupCursorActivation(cursorName);

    if (cursorActivation != null)
    {
      // check we are compiled against the correct cursor
      if (!psName.equals(cursorActivation.getPreparedStatement().getObjectName())) {
View Full Code Here

   * @exception StandardException    Thrown on failure
   */
  public void  executeConstantAction( Activation activation )
            throws StandardException
  {
    LanguageConnectionContext lcc = activation.getLanguageConnectionContext();
    DataDictionary dd = lcc.getDataDictionary();

    /*
    ** Inform the data dictionary that we are about to write to it.
    ** There are several calls to data dictionary "get" methods here
    ** that might be done in "read" mode in the data dictionary, but
View Full Code Here

TOP

Related Classes of org.apache.derby.iapi.sql.conn.LanguageConnectionContext

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.