Examples of SPSDescriptor


Examples of org.apache.derby.iapi.sql.dictionary.SPSDescriptor

    /* Set up the start/stop position for the scan */
    ExecIndexRow keyRow = exFactory.getIndexableRow(1);
    keyRow.setColumn(1, stmtIDOrderable);

    SPSDescriptor spsd = (SPSDescriptor)
          getDescriptorViaIndex(
            SYSSTATEMENTSRowFactory.SYSSTATEMENTS_INDEX1_ID,
            keyRow,
            (ScanQualifier [][]) null,
            ti,
View Full Code Here

Examples of org.apache.derby.iapi.sql.dictionary.SPSDescriptor

   * @exception StandardException    Thrown on failure
   */
  public SPSDescriptor getSPSDescriptor(String stmtName, SchemaDescriptor sd)
    throws StandardException
  {
    SPSDescriptor    sps = null;
    TableKey      stmtKey;
    UUID        schemaUUID;

    /*
    ** If we didn't get a schema descriptor, we had better
View Full Code Here

Examples of org.apache.derby.iapi.sql.dictionary.SPSDescriptor

    /* Set up the start/stop position for the scan */
    ExecIndexRow keyRow = exFactory.getIndexableRow(2);
    keyRow.setColumn(1, stmtNameOrderable);
    keyRow.setColumn(2, schemaIDOrderable);

    SPSDescriptor spsd = (SPSDescriptor)
          getDescriptorViaIndex(
            SYSSTATEMENTSRowFactory.SYSSTATEMENTS_INDEX2_ID,
            keyRow,
            (ScanQualifier [][]) null,
            ti,
            (TupleDescriptor) null,
            (List) null,
            false);
 
    /*
    ** Set up the parameter defaults.  We are only
    ** doing this when we look up by name because
    ** this is the only time we cache, and it can
    ** be foolish to look up the parameter defaults
    ** for someone that doesn't need them.
    */
    if (spsd != null)
    {
      Vector v = new Vector();
      spsd.setParams(getSPSParams(spsd, v));
      Object[] defaults = new Object[v.size()];
      v.copyInto(defaults);
      spsd.setParameterDefaults(defaults);
    }

    return spsd;
  }
View Full Code Here

Examples of org.apache.derby.iapi.sql.dictionary.SPSDescriptor

      ContextService.getContext(LanguageConnectionContext.CONTEXT_ID);
    startWriting(lcc);

    for (java.util.Iterator li = getAllSPSDescriptors().iterator(); li.hasNext(); )
    {
      SPSDescriptor spsd = (SPSDescriptor) li.next();
      spsd.makeInvalid(DependencyManager.USER_RECOMPILE_REQUEST, lcc);
    }
  }
View Full Code Here

Examples of org.apache.derby.iapi.sql.dictionary.SPSDescriptor

   
    while (e.hasMoreElements())
    {
      String spsName = (String)e.nextElement();
      String spsText =  p.getProperty(spsName);
      SPSDescriptor spsd = new SPSDescriptor(this, spsName,
                           getUUIDFactory().createUUID(),
                           schemaID,
                           schemaID,
                           SPSDescriptor.SPS_TYPE_REGULAR,
                           !nocompile,    // it is valid, unless nocompile
View Full Code Here

Examples of org.apache.derby.iapi.sql.dictionary.SPSDescriptor

  protected void dropJDBCMetadataSPSes(TransactionController tc, boolean removeSYSIBMonly)
    throws StandardException
  {
    for (java.util.Iterator it = bootingDictionary.getAllSPSDescriptors().iterator(); it.hasNext(); )
    {
      SPSDescriptor spsd = (SPSDescriptor) it.next();
      SchemaDescriptor sd = spsd.getSchemaDescriptor();
      // need to compare the name, old SYSIBM is not built-in
      boolean isSYSIBM = sd.getSchemaName().equals(SchemaDescriptor.IBM_SYSTEM_SCHEMA_NAME);

      // don't drop statements in non-system schemas
      if (!sd.isSystemSchema() && !isSYSIBM) {
        continue;
      }

      // don't drop statements outside the SYSIBM schema if
      // we're told not to
      if (removeSYSIBMonly && !isSYSIBM) {
        continue;
      }

      bootingDictionary.dropSPSDescriptor(spsd, tc);
      bootingDictionary.dropDependentsStoredDependencies(spsd.getUUID(),
                                 tc);
    }
  }
View Full Code Here

Examples of org.apache.derby.iapi.sql.dictionary.SPSDescriptor

   * @exception StandardException    Thrown on failure
   */
  public SPSDescriptor getSPSDescriptor(UUID uuid)
        throws StandardException
  {
    SPSDescriptor     sps;

    /* Make sure that non-core info is initialized */
    getNonCoreTI(SYSSTATEMENTS_CATALOG_NUM);

    /* Only use the cache if we're in compile-only mode */
    if ((spsNameCache != null) &&
      (getCacheMode() == DataDictionary.COMPILE_ONLY_MODE))
    {
      sps = (SPSDescriptor)spsIdHash.get(uuid);
      if (sps != null)
      {
        //System.out.println("found in hash table ");
        // System.out.println("stmt text " + sps.getText());

        return sps;
      }
 
      sps = getSPSDescriptorIndex2Scan(uuid.toString());
      TableKey stmtKey = new TableKey(sps.getSchemaDescriptor().getUUID(), sps.getName());
      try
      {
        SPSNameCacheable   cacheEntry = (SPSNameCacheable)spsNameCache.create(stmtKey, sps);
        spsNameCache.release(cacheEntry);
      } catch (StandardException se)
View Full Code Here

Examples of org.apache.derby.iapi.sql.dictionary.SPSDescriptor

    /* Set up the start/stop position for the scan */
    ExecIndexRow keyRow = exFactory.getIndexableRow(1);
    keyRow.setColumn(1, stmtIDOrderable);

    SPSDescriptor spsd = (SPSDescriptor)
          getDescriptorViaIndex(
            SYSSTATEMENTSRowFactory.SYSSTATEMENTS_INDEX1_ID,
            keyRow,
            (ScanQualifier [][]) null,
            ti,
View Full Code Here

Examples of org.apache.derby.iapi.sql.dictionary.SPSDescriptor

   * @exception StandardException    Thrown on failure
   */
  public SPSDescriptor getSPSDescriptor(String stmtName, SchemaDescriptor sd)
    throws StandardException
  {
    SPSDescriptor    sps = null;
    TableKey      stmtKey;
    UUID        schemaUUID;

    /*
    ** If we didn't get a schema descriptor, we had better
View Full Code Here

Examples of org.apache.derby.iapi.sql.dictionary.SPSDescriptor

    /* Set up the start/stop position for the scan */
    ExecIndexRow keyRow = exFactory.getIndexableRow(2);
    keyRow.setColumn(1, stmtNameOrderable);
    keyRow.setColumn(2, schemaIDOrderable);

    SPSDescriptor spsd = (SPSDescriptor)
          getDescriptorViaIndex(
            SYSSTATEMENTSRowFactory.SYSSTATEMENTS_INDEX2_ID,
            keyRow,
            (ScanQualifier [][]) null,
            ti,
            (TupleDescriptor) null,
            (List) null,
            false);
 
    /*
    ** Set up the parameter defaults.  We are only
    ** doing this when we look up by name because
    ** this is the only time we cache, and it can
    ** be foolish to look up the parameter defaults
    ** for someone that doesn't need them.
    */
    if (spsd != null)
    {
      Vector v = new Vector();
      spsd.setParams(getSPSParams(spsd, v));
      Object[] defaults = new Object[v.size()];
      v.copyInto(defaults);
      spsd.setParameterDefaults(defaults);
    }

    return spsd;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.