Package com.dkhenry.RethinkDB

Examples of com.dkhenry.RethinkDB.RqlConnection.run()


            RqlCursor cursor = r.run(r.db(database).table(table).insert( l ));
            RqlObject obj = cursor.next();
            Double result = obj.getAs("inserted");
            assert result == rowsPerIteration : "Error inserting Data into Database on iteration " + j + " (" + result + " did not equal " + rowsPerIteration +")";
        }
        RqlCursor cursor = r.run(r.db(database).table(table).count());
        assert Double.valueOf(numberOfIterations*rowsPerIteration).equals(cursor.next().getNumber()) : "Error getting large row count";

        cursor = r.run(r.db(database).table(table));
        long rowCount = 0;
        for(RqlObject o: cursor) {
View Full Code Here


            assert result == rowsPerIteration : "Error inserting Data into Database on iteration " + j + " (" + result + " did not equal " + rowsPerIteration +")";
        }
        RqlCursor cursor = r.run(r.db(database).table(table).count());
        assert Double.valueOf(numberOfIterations*rowsPerIteration).equals(cursor.next().getNumber()) : "Error getting large row count";

        cursor = r.run(r.db(database).table(table));
        long rowCount = 0;
        for(RqlObject o: cursor) {
            rowCount++;
        }
        assert rowCount == (rowsPerIteration * numberOfIterations) : "Error fetching all rows in large dataset";
View Full Code Here

            rowCount++;
        }
        assert rowCount == (rowsPerIteration * numberOfIterations) : "Error fetching all rows in large dataset";
        System.out.println("We got " + rowCount + " results back ");

        r.run(r.db(database).table_drop(table));
        r.run(r.db_drop(database));
        r.close();

    }
}
View Full Code Here

        }
        assert rowCount == (rowsPerIteration * numberOfIterations) : "Error fetching all rows in large dataset";
        System.out.println("We got " + rowCount + " results back ");

        r.run(r.db(database).table_drop(table));
        r.run(r.db_drop(database));
        r.close();

    }
}
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.