diff --git a/jOOQ/src/main/java/org/jooq/impl/DSL.java b/jOOQ/src/main/java/org/jooq/impl/DSL.java
index a3a9aa5acd..568b1ca0be 100644
--- a/jOOQ/src/main/java/org/jooq/impl/DSL.java
+++ b/jOOQ/src/main/java/org/jooq/impl/DSL.java
@@ -16514,26 +16514,32 @@ public class DSL {
/**
* The LN function.
+ *
+ * Get the natural logarithm of a value.
*
* @param value is wrapped as {@link #val(Object)}.
*/
@NotNull
@Support
public static Field
+ * Get the natural logarithm of a value.
*/
@NotNull
@Support
public static Field
+ * Get the logarithm of a value for a base.
*
* @param value is wrapped as {@link #val(Object)}.
* @param base is wrapped as {@link #val(Object)}.
@@ -16546,6 +16552,8 @@ public class DSL {
/**
* The
+ * Get the logarithm of a value for a base.
*
* @param value is wrapped as {@link #val(Object)}.
*/
@@ -16557,6 +16565,8 @@ public class DSL {
/**
* The
+ * Get the logarithm of a value for a base.
*
* @param base is wrapped as {@link #val(Object)}.
*/
@@ -16568,6 +16578,8 @@ public class DSL {
/**
* The
+ * Get the logarithm of a value for a base.
*/
@NotNull
@Support
@@ -16577,6 +16589,8 @@ public class DSL {
/**
* The
+ * Get the logarithm of a value for base 10.
*
* @param value is wrapped as {@link #val(Object)}.
*/
@@ -16588,6 +16602,8 @@ public class DSL {
/**
* The
+ * Get the logarithm of a value for base 10.
*/
@NotNull
@Support
diff --git a/jOOQ/src/main/java/org/jooq/impl/Log.java b/jOOQ/src/main/java/org/jooq/impl/Log.java
index f9bf98df8a..fde298170c 100644
--- a/jOOQ/src/main/java/org/jooq/impl/Log.java
+++ b/jOOQ/src/main/java/org/jooq/impl/Log.java
@@ -63,7 +63,7 @@ import java.math.BigDecimal;
/**
- * The
+ * Get the natural logarithm of a value.
+ */
+ public /*sealed*/ interface Ln
+ extends
+ org.jooq.Field
+ * Get the logarithm of a value for a base.
*/
public /*sealed*/ interface Log
extends
@@ -2613,13 +2630,15 @@ public final class QOM {
// Log
{
@NotNull Field extends Number> $value();
- @Nullable Field extends Number> $base();
+ @NotNull Field extends Number> $base();
@NotNull Log $value(Field extends Number> value);
@NotNull Log $base(Field extends Number> base);
}
/**
* The
+ * Get the logarithm of a value for base 10.
*/
public /*sealed*/ interface Log10
extends
LN function.
+ * LOG function.
+ * LOG function.
+ * LOG function.
+ * LOG function.
+ * LOG10 function.
+ * LOG10 function.
+ * LN statement.
+ * The LOG statement.
*/
@SuppressWarnings({ "rawtypes", "unused" })
final class Log
@@ -76,24 +76,12 @@ implements
final Field extends Number> value;
final Field extends Number> base;
- Log(
- Field extends Number> value
- ) {
- super(
- N_LN,
- allNotNull(NUMERIC, value)
- );
-
- this.value = nullSafeNotNull(value, INTEGER);
- this.base = null;
- }
-
Log(
Field extends Number> value,
Field extends Number> base
) {
super(
- N_LN,
+ N_LOG,
allNotNull(NUMERIC, value, base)
);
@@ -105,42 +93,9 @@ implements
// XXX: QueryPart API
// -------------------------------------------------------------------------
-
-
@Override
public final void accept(Context> ctx) {
- if (base == null) {
- switch (ctx.family()) {
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- case SQLITE:
- ctx.visit(function(N_LOG, NUMERIC, value));
- return;
-
- default:
- ctx.visit(function(N_LN, NUMERIC, value));
- return;
- }
- }
- else {
- switch (ctx.family()) {
+ switch (ctx.family()) {
@@ -167,17 +122,26 @@ implements
- case DERBY:
- case HSQLDB:
- case IGNITE:
- case SQLITE:
- ctx.visit(idiv(DSL.ln(value), DSL.ln(base)));
- return;
- default:
- ctx.visit(function(N_LOG, NUMERIC, base, value));
- return;
- }
+
+
+
+ case DERBY:
+ case HSQLDB:
+ case IGNITE:
+ case SQLITE:
+ ctx.visit(idiv(DSL.ln(value), DSL.ln(base)));
+ break;
+
+
+
+
+
+
+
+ default:
+ ctx.visit(function(N_LOG, NUMERIC, base, value));
+ break;
}
}
@@ -194,8 +158,6 @@ implements
-
-
// -------------------------------------------------------------------------
// XXX: Query Object Model
// -------------------------------------------------------------------------
diff --git a/jOOQ/src/main/java/org/jooq/impl/Patterns.java b/jOOQ/src/main/java/org/jooq/impl/Patterns.java
index f47dfd6eae..22129ba5be 100644
--- a/jOOQ/src/main/java/org/jooq/impl/Patterns.java
+++ b/jOOQ/src/main/java/org/jooq/impl/Patterns.java
@@ -1460,6 +1460,15 @@ package org.jooq.impl;
+
+
+
+
+
+
+
+
+
diff --git a/jOOQ/src/main/java/org/jooq/impl/QOM.java b/jOOQ/src/main/java/org/jooq/impl/QOM.java
index 015befcb72..f0921205db 100644
--- a/jOOQ/src/main/java/org/jooq/impl/QOM.java
+++ b/jOOQ/src/main/java/org/jooq/impl/QOM.java
@@ -2605,6 +2605,23 @@ public final class QOM {
/**
* The LN function.
+ * LOG function.
+ * LOG10 function.
+ *