Examples of resetRowPosition()


Examples of org.voltdb.VoltTable.resetRowPosition()

            } // FOR
            vt.addRow(row);
        } // FOR
        assertEquals(num_rows, vt.getRowCount());
       
        vt.resetRowPosition();
        while (vt.advanceRow()) {
            VoltTableRow row = vt.getRow();
            long w_id = row.getLong(catalog_col.getIndex());
            int p = p_estimator.getTableRowPartition(catalog_tbl, row);
            assert(p >= 0 && p <= NUM_PARTITIONS);
View Full Code Here

Examples of org.voltdb.VoltTable.resetRowPosition()

            } // FOR
            vt.addRow(row);
        } // FOR
        assertEquals(num_rows, vt.getRowCount());
       
        vt.resetRowPosition();
        while (vt.advanceRow()) {
            VoltTableRow row = vt.getRow();
           
            String w_name = row.getString(catalog_col.getIndex());
            int name_p = p_estimator.getHasher().hash(w_name);
View Full Code Here

Examples of org.voltdb.VoltTable.resetRowPosition()

        // TABLE RESULTS
        for (int result_idx = 0; result_idx < num_results; result_idx++) {
            if (result_idx > 0) sb.append("\n\n");
           
            VoltTable vt = results[result_idx];
            vt.resetRowPosition();
            String header[] = new String[vt.getColumnCount()];
            for (int i = 0; i < header.length; i++) {
                String colName = vt.getColumnName(i);
                header[i] = (colName.isEmpty() ? "<empty>" : colName);
            } // FOR
View Full Code Here

Examples of org.voltdb.VoltTable.resetRowPosition()

                                         StringBoxUtil.UNICODE_BOX_HORIZONTAL,
                                         StringBoxUtil.UNICODE_BOX_VERTICAL,
                                         null,
                                         StringBoxUtil.UNICODE_BOX_CORNERS);
            sb.append(StringUtil.prefix(resultTable, "  "));
            vt.resetRowPosition();
        } // FOR
        return (sb.toString());
    }

    /**
 
View Full Code Here

Examples of org.voltdb.VoltTable.resetRowPosition()

            if (!m_constraints.containsKey(key))
                continue;

            VoltTable table = response.getResults()[i];
            orig_position = table.getActiveRowIndex();
            table.resetRowPosition();

            // Iterate through all rows and check if they satisfy the
            // constraints.
            while (isSatisfied && table.advanceRow()) {
                isSatisfied = Verification.checkRow(m_constraints.get(key), table);
View Full Code Here

Examples of org.voltdb.VoltTable.resetRowPosition()

                isSatisfied = Verification.checkRow(m_constraints.get(key), table);
            }

            // Have to reset the position to its original position.
            if (orig_position < 0)
                table.resetRowPosition();
            else
                table.advanceToRow(orig_position);
        }

        if (!isSatisfied)
View Full Code Here

Examples of org.voltdb.VoltTable.resetRowPosition()

                    tuplesRead += (long) stats.getLong("ANTICACHE_TUPLES_READ");
                    blocksRead += (long) stats.getLong("ANTICACHE_BLOCKS_READ");
                    bytesRead += (long) stats.getLong("ANTICACHE_BYTES_READ");
                }
            }
            stats.resetRowPosition();
        }

        // update the rolled up memory statistics
        MemoryStats memoryStats = hstore_site.getMemoryStatsSource();
        memoryStats.eeUpdateMemStats(this.partitionId,
View Full Code Here

Examples of org.voltdb.VoltTable.resetRowPosition()

        System.err.println("-------------------------------");
        System.err.println(VoltTableUtil.format(evictResult));
        assertNotNull(evictResult);
        assertEquals(2, evictResult.getRowCount());
        //assertNotSame(results[0].getColumnCount(), evictResult.getColumnCount());
        evictResult.resetRowPosition();
        boolean adv = evictResult.advanceRow();
        assertTrue(adv);
          return (evictResult);
    }
View Full Code Here

Examples of org.voltdb.VoltTable.resetRowPosition()

        VoltTable results[] = this.ee.getStats(SysProcSelector.TABLE, this.locators, false, 0L);
        assertEquals(1, results.length);
        assertNotNull(results[0]);
        final VoltTable resultTable = results[0];
        assertEquals(2, resultTable.getRowCount());
        resultTable.resetRowPosition();
        System.err.println("-------------------------------");
        System.err.println(VoltTableUtil.format(results));

        resultTable.advanceRow();
        for (String col : statsFields) {
View Full Code Here

Examples of org.voltdb.VoltTable.resetRowPosition()

            // see if we can get the binary value from the '0a1A' update above
            cr = client.callProcedure("Select");
            assertTrue(cr.getStatus() == ClientResponse.SUCCESS);
            VoltTable t = cr.getResults()[0];
            assertEquals(1, t.getRowCount());
            t.resetRowPosition();
            t.advanceRow();
            byte[] vb = t.getVarbinary("b");
            assertEquals(2, vb.length);
            assertEquals((byte) 10, vb[0]);
            assertEquals((byte) 26, vb[1]);
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.