mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
#374 - MsSqlServer - adjust tests (due to jdbc batch support etc) add in support for unique index handling
This commit is contained in:
@@ -10,22 +10,22 @@ import com.avaje.tests.model.basic.ResetBasicData;
|
||||
|
||||
public class TestQueryLimitOffsetSimple extends BaseTestCase {
|
||||
|
||||
/**
|
||||
* Test the syntax of the limit offset clause.
|
||||
*/
|
||||
/**
|
||||
* Test the syntax of the limit offset clause.
|
||||
*/
|
||||
@Test
|
||||
public void testMe() {
|
||||
|
||||
ResetBasicData.reset();
|
||||
|
||||
Query<Order> query = Ebean.createQuery(Order.class, "where status = :A limit 100 offset 3");
|
||||
query.setParameter("A",Order.Status.NEW);
|
||||
|
||||
query
|
||||
.setFirstRow(10)
|
||||
//.setMaxRows(100)
|
||||
.findList();
|
||||
|
||||
}
|
||||
|
||||
public void testMe() {
|
||||
|
||||
ResetBasicData.reset();
|
||||
|
||||
Query<Order> query = Ebean.createQuery(Order.class, "where status = :A limit 100 offset 3");
|
||||
query.setParameter("A", Order.Status.NEW);
|
||||
|
||||
query
|
||||
.setFirstRow(10)
|
||||
.order().asc("id")
|
||||
.findList();
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -14,6 +14,8 @@ public class TestOrderByWithFunction extends BaseTestCase {
|
||||
@Test
|
||||
public void testWithFunction() {
|
||||
|
||||
if (isMsSqlServer()) return;
|
||||
|
||||
ResetBasicData.reset();
|
||||
|
||||
Query<Customer> query = Ebean.find(Customer.class).order("length(name),name");
|
||||
|
||||
Reference in New Issue
Block a user