Package org.apache.derby.iapi.services.io

Examples of org.apache.derby.iapi.services.io.FormatableArrayHolder


    mb.push(innerTable.maxCapacity( (JoinStrategy) this, maxMemoryPerTable));
    /* Get the hash key columns and wrap them in a formattable */
    int[] hashKeyColumns = innerTable.hashKeyColumns();
    FormatableIntHolder[] fihArray =
        FormatableIntHolder.getFormatableIntHolders(hashKeyColumns);
    FormatableArrayHolder hashKeyHolder = new FormatableArrayHolder(fihArray);
    int hashKeyItem = acb.addItem(hashKeyHolder);
    mb.push(hashKeyItem);

    fillInScanArgs2(mb,
            innerTable,
View Full Code Here


                MethodBuilder mb)
              throws StandardException
  {
    int          orderingItem = 0;
    int          aggInfoItem = 0;
    FormatableArrayHolder  orderingHolder;

    /* Get the next ResultSet#, so we can number this ResultSetNode, its
     * ResultColumnList and ResultSet.
     */
    assignResultSetNumber();

    // Get the final cost estimate from the child.
    costEstimate = childResult.getFinalCostEstimate();

    /*
    ** Get the column ordering for the sort.  Note that
    ** for a scalar aggegate we may not have any ordering
    ** columns (if there are no distinct aggregates).
    ** WARNING: if a distinct aggregate is passed to
    ** SortResultSet it assumes that the last column
    ** is the distinct one.  If this assumption changes
    ** then SortResultSet will have to change.
    */
    orderingHolder = acb.getColumnOrdering(groupingList);
    if (addDistinctAggregate)
    {
      orderingHolder = acb.addColumnToOrdering(
                  orderingHolder,
                  addDistinctAggregateColumnNum);
    }

    if (SanityManager.DEBUG)
    {
      if (SanityManager.DEBUG_ON("AggregateTrace"))
      {
        StringBuffer s = new StringBuffer();
         
        s.append("Group by column ordering is (");
        ColumnOrdering[] ordering =
            (ColumnOrdering[])orderingHolder.getArray(ColumnOrdering.class);

        for (int i = 0; i < ordering.length; i++
        {
          s.append(ordering[i].getColumnId());
          s.append(" ");
View Full Code Here

      }
    }

    FormatableIntHolder[] fihArray =
        FormatableIntHolder.getFormatableIntHolders(hashKeyColumns);
    FormatableArrayHolder hashKeyHolder = new FormatableArrayHolder(fihArray);
    int hashKeyItem = acb.addItem(hashKeyHolder);
    long conglomNumber = cd.getConglomerateNumber();
    StaticCompiledOpenConglomInfo scoci = getLanguageConnectionContext().
                        getTransactionCompile().
                          getStaticCompiledConglomInfo(conglomNumber);
View Full Code Here

    }
        singleTableRestriction = str;
    this.nextQualifiers = nextQualifiers;
        projection = p;
    projectMapping = ((ReferencedColumnsDescriptorImpl) a.getPreparedStatement().getSavedObject(mapRefItem)).getReferencedColumnPositions();
    FormatableArrayHolder fah = (FormatableArrayHolder) a.getPreparedStatement().getSavedObject(keyColItem);
    FormatableIntHolder[] fihArray = (FormatableIntHolder[]) fah.getArray(FormatableIntHolder.class);
    keyColumns = new int[fihArray.length];
    for (int index = 0; index < fihArray.length; index++)
    {
      keyColumns[index] = fihArray[index].getInt();
    }
View Full Code Here

    this.forUpdate = forUpdate;
    this.skipNullKeyColumns = skipNullKeyColumns;
    this.keepAfterCommit = activation.getResultSetHoldability();

    /* Retrieve the hash key columns */
    FormatableArrayHolder fah = (FormatableArrayHolder)
                    (activation.getPreparedStatement().
                      getSavedObject(hashKeyItem));
    FormatableIntHolder[] fihArray = (FormatableIntHolder[]) fah.getArray(FormatableIntHolder.class);
    keyColumns = new int[fihArray.length];
    for (int index = 0; index < fihArray.length; index++)
    {
      keyColumns[index] = fihArray[index].getInt();
    }
View Full Code Here

    // Save the hash key columns

    FormatableIntHolder[] fihArray =
        FormatableIntHolder.getFormatableIntHolders(hashKeyColumns());
    FormatableArrayHolder hashKeyHolder = new FormatableArrayHolder(fihArray);
    int hashKeyItem = acb.addItem(hashKeyHolder);

    /* Generate the HashTableResultSet:
     *  arg1: childExpress - Expression for childResultSet
     *  arg2: searchExpress - Expression for single table predicates
View Full Code Here

    mb.push(innerTable.maxCapacity( (JoinStrategy) this, maxMemoryPerTable));
    /* Get the hash key columns and wrap them in a formattable */
    int[] hashKeyColumns = innerTable.hashKeyColumns();
    FormatableIntHolder[] fihArray =
        FormatableIntHolder.getFormatableIntHolders(hashKeyColumns);
    FormatableArrayHolder hashKeyHolder = new FormatableArrayHolder(fihArray);
    int hashKeyItem = acb.addItem(hashKeyHolder);
    mb.push(hashKeyItem);

    fillInScanArgs2(mb,
            innerTable,
View Full Code Here

      {
        ordering[j] = new IndexColumnOrder(i);
        j++;
      }
    }
    return new FormatableArrayHolder(ordering);
  }
View Full Code Here

    */
    IndexColumnOrder[] newOrdering = new IndexColumnOrder[length+1];
    System.arraycopy(ordering, 0, newOrdering, 0, length);
    newOrdering[length] = new IndexColumnOrder(columnNum);
   
    return new FormatableArrayHolder(newOrdering);
 
View Full Code Here

  FormatableArrayHolder getColumnOrdering(OrderedColumnList  oclist) {
    int numCols = (oclist == null) ? 0 : oclist.size();

    if (numCols == 0)
    {
      return new FormatableArrayHolder(new IndexColumnOrder[0]);
    }

    return new FormatableArrayHolder(oclist.getColumnOrdering());
  }
View Full Code Here

TOP

Related Classes of org.apache.derby.iapi.services.io.FormatableArrayHolder

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.