diff --git a/jOOQ-test/src/org/jooq/test/_/testcases/PredicateTests.java b/jOOQ-test/src/org/jooq/test/_/testcases/PredicateTests.java
index cc197da8bd..fb6087b34f 100644
--- a/jOOQ-test/src/org/jooq/test/_/testcases/PredicateTests.java
+++ b/jOOQ-test/src/org/jooq/test/_/testcases/PredicateTests.java
@@ -42,6 +42,8 @@ import static org.jooq.SQLDialect.DB2;
import static org.jooq.SQLDialect.DERBY;
import static org.jooq.SQLDialect.MYSQL;
import static org.jooq.conf.StatementType.STATIC_STATEMENT;
+import static org.jooq.impl.Factory.all;
+import static org.jooq.impl.Factory.any;
import static org.jooq.impl.Factory.castNull;
import static org.jooq.impl.Factory.concat;
import static org.jooq.impl.Factory.count;
@@ -494,41 +496,41 @@ extends BaseTest extends QueryPart {
*
* The name is any of these:
*
- * This renders the same on all dialects:
- *
* This renders the modulo operation where available:
- *
* This renders the modulo operation where available:
- *
- *
*
*
+ * This renders the same on all dialects: -[this]
*/
@Support
Field-[this]
- * ... or the modulo function elsewhere:
- * [this] % [value]
+ * mod([this], [value])
... or the modulo function
+ * elsewhere: [this] % [value]
*/
@Support
Fieldmod([this], [value])
- * ... or the modulo function elsewhere:
- * [this] % [value]
+ * mod([this], [value])
... or the modulo function
+ * elsewhere: [this] % [value]
*/
@Support
Fieldmod([this], [value])
* [search] REGEXP [pattern]POSIX
* http://dev.mysql.com/doc/refman/5.6/en/regexp.html
+ * "http://dev.mysql.com/doc/refman/5.6/en/regexp.html">http://dev
+ * .mysql.com/doc/refman/5.6/en/regexp.html
- * This is the same as calling
- * between(minValue).and(maxValue)
+ * This is the same as calling between(minValue).and(maxValue)
*
* SQL:
- * This is the same as calling
- *
* SQL:
@@ -1328,6 +1337,19 @@ public interface Field
@@ -1350,6 +1372,19 @@ public interface Field
@@ -1378,6 +1413,19 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition equalAny(T... array);
@@ -1614,13 +1774,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, CUBRID, HSQLDB, POSTGRES })
Condition equalAny(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition equalAll(T... array);
@@ -1638,13 +1810,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition equalAll(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition notEqualAny(T... array);
@@ -1662,13 +1846,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition notEqualAny(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition notEqualAll(T... array);
@@ -1686,13 +1882,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition notEqualAll(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition lessThanAny(T... array);
@@ -1710,13 +1918,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition lessThanAny(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition lessThanAll(T... array);
@@ -1734,13 +1954,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition lessThanAll(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition lessOrEqualAny(T... array);
@@ -1758,13 +1990,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition lessOrEqualAny(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition lessOrEqualAll(T... array);
@@ -1782,13 +2026,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition lessOrEqualAll(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition greaterThanAny(T... array);
@@ -1806,13 +2062,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition greaterThanAny(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition greaterThanAll(T... array);
@@ -1830,13 +2098,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition greaterThanAll(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition greaterOrEqualAny(T... array);
@@ -1854,13 +2134,21 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition greaterOrEqualAny(Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Object...)} instead
+ * for quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition greaterOrEqualAll(T... array);
@@ -1878,7 +2170,11 @@ public interface Field
* This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
* will render a subselect unnesting the array.
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Field)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ H2, HSQLDB, POSTGRES })
Condition greaterOrEqualAll(Field
+ * A
+ * This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
+ * will render a subselect unnesting the array.
+ *
+ * @see Field#equal(QuantifiedSelect)
+ * @see Field#notEqual(QuantifiedSelect)
+ * @see Field#greaterThan(QuantifiedSelect)
+ * @see Field#greaterOrEqual(QuantifiedSelect)
+ * @see Field#lessThan(QuantifiedSelect)
+ * @see Field#lessOrEqual(QuantifiedSelect)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ public static
+ * This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
+ * will render a subselect unnesting the array.
+ *
+ * @see Field#equal(QuantifiedSelect)
+ * @see Field#notEqual(QuantifiedSelect)
+ * @see Field#greaterThan(QuantifiedSelect)
+ * @see Field#greaterOrEqual(QuantifiedSelect)
+ * @see Field#lessThan(QuantifiedSelect)
+ * @see Field#lessOrEqual(QuantifiedSelect)
+ */
+ @Support({ H2, HSQLDB, POSTGRES })
+ public static
+ * This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
+ * will render a subselect unnesting the array.
+ *
+ * @see Field#equal(QuantifiedSelect)
+ * @see Field#notEqual(QuantifiedSelect)
+ * @see Field#greaterThan(QuantifiedSelect)
+ * @see Field#greaterOrEqual(QuantifiedSelect)
+ * @see Field#lessThan(QuantifiedSelect)
+ * @see Field#lessOrEqual(QuantifiedSelect)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ public static
+ * This is natively supported by {@link SQLDialect#POSTGRES}. Other dialects
+ * will render a subselect unnesting the array.
+ *
+ * @see Field#equal(QuantifiedSelect)
+ * @see Field#notEqual(QuantifiedSelect)
+ * @see Field#greaterThan(QuantifiedSelect)
+ * @see Field#greaterOrEqual(QuantifiedSelect)
+ * @see Field#lessThan(QuantifiedSelect)
+ * @see Field#lessOrEqual(QuantifiedSelect)
+ */
+ @Support({ H2, HSQLDB, POSTGRES })
+ public static this between minValue and maxValue
*/
@@ -1114,8 +1111,7 @@ public interface Fieldbetween(minValue).and(maxValue)
+ * This is the same as calling between(minValue).and(maxValue)
* this between minValue and maxValue
*/
@@ -1300,6 +1296,19 @@ public interface Fieldthis = [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition equal(QuantifiedSelect> query);
+
/**
* this = value
* this = [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition eq(QuantifiedSelect> query);
+
/**
* this != value
* this != [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition notEqual(QuantifiedSelect> query);
+
/**
* this != value
* this != [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition ne(QuantifiedSelect> query);
+
/**
* this < value
*/
@@ -1396,6 +1444,19 @@ public interface Fieldthis < [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition lessThan(QuantifiedSelect> query);
+
/**
* this < value
*
@@ -1420,6 +1481,19 @@ public interface Fieldthis < [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition lt(QuantifiedSelect> query);
+
/**
* this <= value
*/
@@ -1438,6 +1512,19 @@ public interface Fieldthis <= [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition lessOrEqual(QuantifiedSelect> query);
+
/**
* this <= value
*
@@ -1462,6 +1549,19 @@ public interface Fieldthis <= [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition le(QuantifiedSelect> query);
+
/**
* this > value
*/
@@ -1480,6 +1580,19 @@ public interface Fieldthis > [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition greaterThan(QuantifiedSelect> query);
+
/**
* this > value
*
@@ -1504,6 +1617,19 @@ public interface Fieldthis > [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition gt(QuantifiedSelect> query);
+
/**
* this >= value
*/
@@ -1522,6 +1648,19 @@ public interface Fieldthis >= [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition greaterOrEqual(QuantifiedSelect> query);
+
/**
* this >= value
*
@@ -1546,6 +1685,19 @@ public interface Fieldthis >= [quantifier] (Select> ...)
+ *
+ * @see Factory#all(Field)
+ * @see Factory#all(Select)
+ * @see Factory#all(Object...)
+ * @see Factory#any(Field)
+ * @see Factory#any(Select)
+ * @see Factory#any(Object...)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ Condition ge(QuantifiedSelect> query);
+
/**
* Create a condition to check this field against known string literals for
* true
@@ -1596,7 +1748,11 @@ public interface Fieldthis = any (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition equalAny(Select> query);
@@ -1605,7 +1761,11 @@ public interface Fieldthis = all (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition equalAll(Select> query);
@@ -1629,7 +1797,11 @@ public interface Fieldthis != any (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition notEqualAny(Select> query);
@@ -1653,7 +1833,11 @@ public interface Fieldthis != all (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition notEqualAll(Select> query);
@@ -1677,7 +1869,11 @@ public interface Fieldthis < any (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition lessThanAny(Select> query);
@@ -1701,7 +1905,11 @@ public interface Fieldthis < all (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition lessThanAll(Select> query);
@@ -1725,7 +1941,11 @@ public interface Fieldthis <= any (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition lessOrEqualAny(Select> query);
@@ -1749,7 +1977,11 @@ public interface Fieldthis <= all (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition lessOrEqualAll(Select> query);
@@ -1773,7 +2013,11 @@ public interface Fieldthis > any (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition greaterThanAny(Select> query);
@@ -1797,7 +2049,11 @@ public interface Fieldthis > all (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition greaterThanAll(Select> query);
@@ -1821,7 +2085,11 @@ public interface Fieldthis >= any (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#any(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition greaterOrEqualAny(Select> query);
@@ -1845,7 +2121,11 @@ public interface Fieldthis >= all (Select> ...)
+ *
+ * @deprecated - 2.7.0 [#1697] - Use {@link Factory#all(Select)} instead for
+ * quantified comparison predicates
*/
+ @Deprecated
@Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
Condition greaterOrEqualAll(Select> query);
@@ -1869,7 +2157,11 @@ public interface FieldQuantifiedSelect models the right hand side of a quantified
+ * comparison predicate. Examples of such predicates:
+ *
+ *
+ * These predicates can be used exclusively with methods, such as {@link Field}
+ *
+ * @author Lukas Eder
+ */
+public interface QuantifiedSelectANY (SELECT 1 FROM DUAL)ALL (SELECT 1 FROM DUAL)ALL quantified select to be used in quantified
+ * comparison predicate expressions.
+ *
+ * @see Field#equal(QuantifiedSelect)
+ * @see Field#notEqual(QuantifiedSelect)
+ * @see Field#greaterThan(QuantifiedSelect)
+ * @see Field#greaterOrEqual(QuantifiedSelect)
+ * @see Field#lessThan(QuantifiedSelect)
+ * @see Field#lessOrEqual(QuantifiedSelect)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ public static ALL quantified select to be used in quantified
+ * comparison predicate expressions.
+ * ALL quantified select to be used in quantified
+ * comparison predicate expressions.
+ * ANY quantified select to be used in quantified
+ * comparison predicate expressions.
+ *
+ * @see Field#equal(QuantifiedSelect)
+ * @see Field#notEqual(QuantifiedSelect)
+ * @see Field#greaterThan(QuantifiedSelect)
+ * @see Field#greaterOrEqual(QuantifiedSelect)
+ * @see Field#lessThan(QuantifiedSelect)
+ * @see Field#lessOrEqual(QuantifiedSelect)
+ */
+ @Support({ ASE, CUBRID, DB2, DERBY, FIREBIRD, H2, HSQLDB, INGRES, MYSQL, ORACLE, POSTGRES, SQLSERVER, SYBASE })
+ public static ANY quantified select to be used in quantified
+ * comparison predicate expressions.
+ * ANY quantified select to be used in quantified
+ * comparison predicate expressions.
+ * ANY quantifier
+ */
+ ANY("any"),
+
+ /**
+ * The ALL quantifier
+ */
+ ALL("all"),
+
+ ;
+
+ private final String sql;
+
+ private Quantifier(String sql) {
+ this.sql = sql;
+ }
+
+ public String toSQL() {
+ return sql;
+ }
+}
diff --git a/jOOQ/src/main/java/org/jooq/impl/SubQueryOperator.java b/jOOQ/src/main/java/org/jooq/impl/SubQueryOperator.java
index 1d6f208b93..fa340b6791 100644
--- a/jOOQ/src/main/java/org/jooq/impl/SubQueryOperator.java
+++ b/jOOQ/src/main/java/org/jooq/impl/SubQueryOperator.java
@@ -46,23 +46,13 @@ enum SubQueryOperator {
IN("in"),
NOT_IN("not in"),
EQUALS("="),
- EQUALS_ANY("= any"),
- EQUALS_ALL("= all"),
NOT_EQUALS("<>"),
- NOT_EQUALS_ANY("<> any"),
- NOT_EQUALS_ALL("<> all"),
LESS("<"),
- LESS_THAN_ANY("< any"),
- LESS_THAN_ALL("< all"),
LESS_OR_EQUAL("<="),
- LESS_OR_EQUAL_ANY("<= any"),
- LESS_OR_EQUAL_ALL("<= all"),
GREATER(">"),
- GREATER_THAN_ANY("> any"),
- GREATER_THAN_ALL("> all"),
GREATER_OR_EQUAL(">="),
- GREATER_OR_EQUAL_ANY(">= any"),
- GREATER_OR_EQUAL_ALL(">= all"), ;
+
+ ;
private final String sql;
diff --git a/jOOQ/src/test/java/org/jooq/test/BasicTest.java b/jOOQ/src/test/java/org/jooq/test/BasicTest.java
index 7973f6606f..3cc181ae29 100644
--- a/jOOQ/src/test/java/org/jooq/test/BasicTest.java
+++ b/jOOQ/src/test/java/org/jooq/test/BasicTest.java
@@ -39,6 +39,7 @@ package org.jooq.test;
import static junit.framework.Assert.assertEquals;
import static junit.framework.Assert.assertTrue;
import static org.jooq.JoinType.LEFT_OUTER_JOIN;
+import static org.jooq.impl.Factory.any;
import static org.jooq.impl.Factory.avg;
import static org.jooq.impl.Factory.condition;
import static org.jooq.impl.Factory.count;
@@ -2357,7 +2358,7 @@ public class BasicTest {
q2.addFrom(TABLE2);
q2.addSelect(FIELD_ID2);
- q1.addConditions(FIELD_ID1.greaterThanAny(q2));
+ q1.addConditions(FIELD_ID1.greaterThan(any(q2)));
assertEquals("select \"TABLE1\".\"ID1\", \"TABLE1\".\"NAME1\", \"TABLE1\".\"DATE1\" from \"TABLE1\" where \"TABLE1\".\"ID1\" > any (select \"TABLE2\".\"ID2\" from \"TABLE2\")", r_refI().render(q1));
assertEquals("select \"TABLE1\".\"ID1\", \"TABLE1\".\"NAME1\", \"TABLE1\".\"DATE1\" from \"TABLE1\" where \"TABLE1\".\"ID1\" > any (select \"TABLE2\".\"ID2\" from \"TABLE2\")", r_ref().render(q1));