Package org.voltdb

Examples of org.voltdb.VoltTable.fetchRow()


        assert((initialYTD + paymentAmount) == districts.fetchRow(0).getDouble("D_YTD"));

        voltQueueSQL(getCustomers);
        VoltTable customersX = voltExecuteSQL()[0];
        assert(4 == customersX.getRowCount());
        assert((C_ID + 1) == customersX.fetchRow(1).getLong("C_ID"));
        assert((initialBalance - paymentAmount) == customersX.fetchRow(1).getDouble("C_BALANCE"));
        assert((initialYTD + paymentAmount) == customersX.fetchRow(1).getDouble("C_YTD_PAYMENT"));
        assert(2 == customersX.fetchRow(1).getLong("C_PAYMENT_CNT"));

        return null;
View Full Code Here


        voltQueueSQL(getCustomers);
        VoltTable customersX = voltExecuteSQL()[0];
        assert(4 == customersX.getRowCount());
        assert((C_ID + 1) == customersX.fetchRow(1).getLong("C_ID"));
        assert((initialBalance - paymentAmount) == customersX.fetchRow(1).getDouble("C_BALANCE"));
        assert((initialYTD + paymentAmount) == customersX.fetchRow(1).getDouble("C_YTD_PAYMENT"));
        assert(2 == customersX.fetchRow(1).getLong("C_PAYMENT_CNT"));

        return null;
    }
View Full Code Here

        voltQueueSQL(getCustomers);
        VoltTable customersX = voltExecuteSQL()[0];
        assert(4 == customersX.getRowCount());
        assert((C_ID + 1) == customersX.fetchRow(1).getLong("C_ID"));
        assert((initialBalance - paymentAmount) == customersX.fetchRow(1).getDouble("C_BALANCE"));
        assert((initialYTD + paymentAmount) == customersX.fetchRow(1).getDouble("C_YTD_PAYMENT"));
        assert(2 == customersX.fetchRow(1).getLong("C_PAYMENT_CNT"));

        return null;
    }
}
View Full Code Here

        VoltTable customersX = voltExecuteSQL()[0];
        assert(4 == customersX.getRowCount());
        assert((C_ID + 1) == customersX.fetchRow(1).getLong("C_ID"));
        assert((initialBalance - paymentAmount) == customersX.fetchRow(1).getDouble("C_BALANCE"));
        assert((initialYTD + paymentAmount) == customersX.fetchRow(1).getDouble("C_YTD_PAYMENT"));
        assert(2 == customersX.fetchRow(1).getLong("C_PAYMENT_CNT"));

        return null;
    }
}
View Full Code Here

        voltQueueSQL(truncate);
        voltQueueSQL(count);
        voltQueueSQL(scancount);
        VoltTable[] results = voltExecuteSQL(true);
        VoltTable data = results[1];
        VoltTableRow row = data.fetchRow(0);
        long optCount = row.getLong(0);
        if (optCount != 0) {
            throw new VoltAbortException("after truncate (opt) count not zero");
        }
        data = results[2];
View Full Code Here

        long optCount = row.getLong(0);
        if (optCount != 0) {
            throw new VoltAbortException("after truncate (opt) count not zero");
        }
        data = results[2];
        row = data.fetchRow(0);
        long scanCount = row.getLong(0);
        if (scanCount != 0) {
            throw new VoltAbortException("after truncate (scan) count not zero");
        }
        if (shouldRollback != 0) {
View Full Code Here

            // Randomly decide whether to delete (or update) the record
            if (rand.nextBoolean())
            {
                voltQueueSQL(delete, rowid);
                // Export deletion
                VoltTableRow row = item.fetchRow(0);
                voltQueueSQL(
                              export
                            , txid
                            , rowid
                            , row.get( 1, VoltType.TINYINT)
View Full Code Here

        voltQueueSQL(truncate);
        voltQueueSQL(count);
        voltQueueSQL(scancount);
        VoltTable[] results = voltExecuteSQL(true);
        VoltTable data = results[1];
        VoltTableRow row = data.fetchRow(0);
        long optCount = row.getLong(0);
        if (optCount != 0) {
            throw new VoltAbortException("after truncate (opt) count not zero");
        }
        data = results[2];
View Full Code Here

        long optCount = row.getLong(0);
        if (optCount != 0) {
            throw new VoltAbortException("after truncate (opt) count not zero");
        }
        data = results[2];
        row = data.fetchRow(0);
        long scanCount = row.getLong(0);
        if (scanCount != 0) {
            throw new VoltAbortException("after truncate (scan) count not zero");
        }
        if (shouldRollback != 0) {
View Full Code Here

        double prevBidPrice = -1;
        long prevBidTime = -1;

        // make sure that we get a row before reading this info
        if (highBidResult.getRowCount() == 1) {
            prevBidderID = highBidResult.fetchRow(0).getLong("BIDDERID");
            prevBidPrice = highBidResult.fetchRow(0).getDouble("BIDPRICE");
            prevBidTime = highBidResult.fetchRow(0).getTimestampAsLong("BIDTIME");
        }

        // get the current seller id
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.