mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
#1943 - Return ExpressionList<T> from setMaxRows() setFirstRow() to allow fluid style
This is to allow fluid style use of setMaxRows() setFirstRow() with filterMany query
This commit is contained in:
@@ -196,7 +196,7 @@ public class TestQueryFindIterate extends BaseTestCase {
|
||||
Query<Customer> query = server.find(Customer.class)
|
||||
.setAutoTune(false)
|
||||
.where().gt("id", "JUNK_NOT_A_LONG")
|
||||
.setMaxRows(2);
|
||||
.setMaxRows(2).query();
|
||||
|
||||
// this throws an exception immediately
|
||||
query.findEach(bean -> {
|
||||
@@ -221,7 +221,7 @@ public class TestQueryFindIterate extends BaseTestCase {
|
||||
Query<Customer> query = server.find(Customer.class)
|
||||
.setAutoTune(false)
|
||||
.where().gt("id", 0)
|
||||
.setMaxRows(2);
|
||||
.setMaxRows(2).query();
|
||||
|
||||
query.findEach(customer -> {
|
||||
if (customer != null) {
|
||||
|
||||
Reference in New Issue
Block a user