/** @see IndexDescriptor#baseColumnPositions */ public int[] baseColumnPositions() { return id.baseColumnPositions(); }
/** @see IndexDescriptor#baseColumnPositions */ public int[] baseColumnPositions() { return id.baseColumnPositions(); }
/** @see IndexDescriptor#baseColumnPositions */ public int[] baseColumnPositions() { return id.baseColumnPositions(); }
/** * Get a template for the index row, to be used with getIndexRow. * * @return A row template for the index row. */ public ExecIndexRow getIndexRowTemplate() { return getExecutionFactory().getIndexableRow( id.baseColumnPositions().length + 1); }
/** * Get a template for the index row, to be used with getIndexRow. * * @return A row template for the index row. */ public ExecIndexRow getIndexRowTemplate() { return getExecutionFactory().getIndexableRow( id.baseColumnPositions().length + 1); }
/** * Get a template for the index row, to be used with getIndexRow. * * @return A row template for the index row. */ public ExecIndexRow getIndexRowTemplate() { return getExecutionFactory().getIndexableRow( id.baseColumnPositions().length + 1); }
/** * Create a boolean[] to track the (0-based) columns which are indexed. * * @return A boolean[] to track the (0-based) columns which are indexed. * * @exception StandardException Thrown on failure */ public boolean[] getIndexedCols() throws StandardException { /* Create a boolean[] to track the (0-based) columns which are indexed */ boolean[] indexedCols = new boolean[targetTableDescriptor.getNumberOfColumns()]; for (int index = 0; index < indicesToMaintain.length; index++) { int[] colIds = indicesToMaintain[index].getIndexDescriptor().baseColumnPositions(); for (int index2 = 0; index2 < colIds.length; index2++) { indexedCols[colIds[index2] - 1] = true; } } return indexedCols; }
/** * Create a boolean[] to track the (0-based) columns which are indexed. * * @return A boolean[] to track the (0-based) columns which are indexed. * * @exception StandardException Thrown on failure */ public boolean[] getIndexedCols() throws StandardException { /* Create a boolean[] to track the (0-based) columns which are indexed */ boolean[] indexedCols = new boolean[targetTableDescriptor.getNumberOfColumns()]; for (int index = 0; index < indicesToMaintain.length; index++) { int[] colIds = indicesToMaintain[index].getIndexDescriptor().baseColumnPositions(); for (int index2 = 0; index2 < colIds.length; index2++) { indexedCols[colIds[index2] - 1] = true; } } return indexedCols; }
/** * Create a boolean[] to track the (0-based) columns which are indexed. * * @return A boolean[] to track the (0-based) columns which are indexed. * * @exception StandardException Thrown on failure */ public boolean[] getIndexedCols() throws StandardException { /* Create a boolean[] to track the (0-based) columns which are indexed */ boolean[] indexedCols = new boolean[targetTableDescriptor.getNumberOfColumns()]; for (int index = 0; index < indicesToMaintain.length; index++) { int[] colIds = indicesToMaintain[index].getIndexDescriptor().baseColumnPositions(); for (int index2 = 0; index2 < colIds.length; index2++) { indexedCols[colIds[index2] - 1] = true; } } return indexedCols; }
private List<ConglomerateDescriptor> sortGlobalIndexesOnBaseColumns( TableDescriptor td) { ConglomerateDescriptorList cdl = td.getConglomerateDescriptorList(); Iterator itr = cdl.iterator(); List<ConglomerateDescriptor> sortedIndexes = new LinkedList<ConglomerateDescriptor>(); while (itr.hasNext()) { ConglomerateDescriptor cd = (ConglomerateDescriptor)itr.next(); if (cd.isIndex() || cd.isConstraint()) { IndexDescriptor id = cd.getIndexDescriptor(); if (id.indexType().equals(GfxdConstants.GLOBAL_HASH_INDEX_TYPE)) { int[] baseColPos = id.baseColumnPositions(); ListIterator<ConglomerateDescriptor> li = sortedIndexes .listIterator(); while (li.hasNext()) { ConglomerateDescriptor currSorted = li.next(); if (baseColPos.length > currSorted.getIndexDescriptor() .baseColumnPositions().length) { break; } } li.add(cd); } } } return sortedIndexes; }
private List<ConglomerateDescriptor> sortGlobalIndexesOnBaseColumns( TableDescriptor td) { ConglomerateDescriptorList cdl = td.getConglomerateDescriptorList(); Iterator itr = cdl.iterator(); List<ConglomerateDescriptor> sortedIndexes = new LinkedList<ConglomerateDescriptor>(); while (itr.hasNext()) { ConglomerateDescriptor cd = (ConglomerateDescriptor)itr.next(); if (cd.isIndex() || cd.isConstraint()) { IndexDescriptor id = cd.getIndexDescriptor(); if (id.indexType().equals(GfxdConstants.GLOBAL_HASH_INDEX_TYPE)) { int[] baseColPos = id.baseColumnPositions(); ListIterator<ConglomerateDescriptor> li = sortedIndexes .listIterator(); while (li.hasNext()) { ConglomerateDescriptor currSorted = li.next(); if (baseColPos.length > currSorted.getIndexDescriptor() .baseColumnPositions().length) { break; } } li.add(cd); } } } return sortedIndexes; }
private List<ConglomerateDescriptor> sortGlobalIndexesOnBaseColumns( TableDescriptor td) { ConglomerateDescriptorList cdl = td.getConglomerateDescriptorList(); Iterator itr = cdl.iterator(); List<ConglomerateDescriptor> sortedIndexes = new LinkedList<ConglomerateDescriptor>(); while (itr.hasNext()) { ConglomerateDescriptor cd = (ConglomerateDescriptor)itr.next(); if (cd.isIndex() || cd.isConstraint()) { IndexDescriptor id = cd.getIndexDescriptor(); if (id.indexType().equals(GfxdConstants.GLOBAL_HASH_INDEX_TYPE)) { int[] baseColPos = id.baseColumnPositions(); ListIterator<ConglomerateDescriptor> li = sortedIndexes .listIterator(); while (li.hasNext()) { ConglomerateDescriptor currSorted = li.next(); if (baseColPos.length > currSorted.getIndexDescriptor() .baseColumnPositions().length) { break; } } li.add(cd); } } } return sortedIndexes; }
List<ConglomerateDescriptor> getAvailableGlobalHashIndexForColumn() { if (this.tqi == null) { return Collections.emptyList(); } TableDescriptor td = this.tqi.getTableDescriptor(); assert td != null; ConglomerateDescriptorList cdl = td.getConglomerateDescriptorList(); Iterator itr = cdl.iterator(); List<ConglomerateDescriptor> globalIndexes = new ArrayList<ConglomerateDescriptor>( 2); while (itr.hasNext()) { ConglomerateDescriptor cd = (ConglomerateDescriptor)itr.next(); if (cd.isIndex() || cd.isConstraint()) { IndexDescriptor id = cd.getIndexDescriptor(); if (id.indexType().equals(GfxdConstants.GLOBAL_HASH_INDEX_TYPE)) { int[] baseColPos = id.baseColumnPositions(); for (int colPos : baseColPos) { if (colPos == this.actualColumnNumber) { globalIndexes.add(cd); break; } } } } } return globalIndexes; }
List<ConglomerateDescriptor> getAvailableGlobalHashIndexForColumn() { if (this.tqi == null) { return Collections.emptyList(); } TableDescriptor td = this.tqi.getTableDescriptor(); assert td != null; ConglomerateDescriptorList cdl = td.getConglomerateDescriptorList(); Iterator itr = cdl.iterator(); List<ConglomerateDescriptor> globalIndexes = new ArrayList<ConglomerateDescriptor>( 2); while (itr.hasNext()) { ConglomerateDescriptor cd = (ConglomerateDescriptor)itr.next(); if (cd.isIndex() || cd.isConstraint()) { IndexDescriptor id = cd.getIndexDescriptor(); if (id.indexType().equals(GfxdConstants.GLOBAL_HASH_INDEX_TYPE)) { int[] baseColPos = id.baseColumnPositions(); for (int colPos : baseColPos) { if (colPos == this.actualColumnNumber) { globalIndexes.add(cd); break; } } } } } return globalIndexes; }
List<ConglomerateDescriptor> getAvailableGlobalHashIndexForColumn() { if (this.tqi == null) { return Collections.emptyList(); } TableDescriptor td = this.tqi.getTableDescriptor(); assert td != null; ConglomerateDescriptorList cdl = td.getConglomerateDescriptorList(); Iterator itr = cdl.iterator(); List<ConglomerateDescriptor> globalIndexes = new ArrayList<ConglomerateDescriptor>( 2); while (itr.hasNext()) { ConglomerateDescriptor cd = (ConglomerateDescriptor)itr.next(); if (cd.isIndex() || cd.isConstraint()) { IndexDescriptor id = cd.getIndexDescriptor(); if (id.indexType().equals(GfxdConstants.GLOBAL_HASH_INDEX_TYPE)) { int[] baseColPos = id.baseColumnPositions(); for (int colPos : baseColPos) { if (colPos == this.actualColumnNumber) { globalIndexes.add(cd); break; } } } } } return globalIndexes; }
throws StandardException int[] base_cols = id.baseColumnPositions(); int[] collation_ids = new int[base_cols.length + 1];
throws StandardException int[] base_cols = id.baseColumnPositions(); int[] collation_ids = new int[base_cols.length + 1];
throws StandardException int[] base_cols = id.baseColumnPositions(); int[] collation_ids = new int[base_cols.length + 1];
int[] keyColumns = id.baseColumnPositions();
IndexDescriptor id = cd.getIndexDescriptor(); if (id.indexType().equals(GfxdConstants.GLOBAL_HASH_INDEX_TYPE)) { int[] baseColPos = id.baseColumnPositions(); if (baseColPos.length == pkMap.size()) { int cnt = 0;