[#3600] Add support for SQL standard SELECT .. WITH CHECK OPTION
This commit is contained in:
parent
4b9fd5c63b
commit
853e4a0a7e
@ -123,4 +123,18 @@ public interface SelectForUpdateStep<R extends Record> extends SelectOptionStep<
|
||||
@Support({ MARIADB, MYSQL, POSTGRES })
|
||||
SelectOptionStep<R> forShare();
|
||||
|
||||
/* [pro] xx
|
||||
xxx
|
||||
x xxx x xxxxxxxxxx xxxxx xxxxxxxxxxxxx xxxxxx xx xxx xxx xx xxx xxxxxxxxx
|
||||
xx
|
||||
xxxxxxxxxx xxxxxx xx
|
||||
xxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxxx
|
||||
|
||||
xxx
|
||||
x xxx x xxxxxxxxxx xxxx xxxxxxxxxxx xxxxxx xx xxx xxx xx xxx xxxxxxxxx
|
||||
xx
|
||||
xxxxxxxxxx xxxxxx xx
|
||||
xxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxx
|
||||
xx [/pro] */
|
||||
|
||||
}
|
||||
|
||||
@ -818,4 +818,18 @@ public interface SelectQuery<R extends Record> extends Select<R>, ConditionProvi
|
||||
@Support({ MARIADB, MYSQL, POSTGRES })
|
||||
void setForShare(boolean forShare);
|
||||
|
||||
/* [pro] xx
|
||||
xxx
|
||||
x xxx x xxxxxxxxxx xxxxx xxxxxxxxxxxxx xxxxxx xx xxx xxx xx xxx xxxxxxxxx
|
||||
xx
|
||||
xxxxxxxxxx xxxxxx xx
|
||||
xxxx xxxxxxxxxxxxxxxxxxxxx
|
||||
|
||||
xxx
|
||||
x xxx x xxxxxxxxxx xxxx xxxxxxxxxxx xxxxxx xx xxx xxx xx xxx xxxxxxxxx
|
||||
xx
|
||||
xxxxxxxxxx xxxxxx xx
|
||||
xxxx xxxxxxxxxxxxxxxxxx
|
||||
xx [/pro] */
|
||||
|
||||
}
|
||||
|
||||
@ -75,6 +75,7 @@ import org.jooq.Row;
|
||||
import org.jooq.Select;
|
||||
import org.jooq.SelectConditionStep;
|
||||
import org.jooq.SelectConnectByConditionStep;
|
||||
import org.jooq.SelectFinalStep;
|
||||
import org.jooq.SelectForUpdateOfStep;
|
||||
import org.jooq.SelectHavingConditionStep;
|
||||
import org.jooq.SelectIntoStep;
|
||||
@ -1837,6 +1838,20 @@ class SelectImpl<R extends Record, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11,
|
||||
return this;
|
||||
}
|
||||
|
||||
/* [pro] xx
|
||||
xxxxxxxxx
|
||||
xxxxxx xxxxx xxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxx x
|
||||
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
||||
xxxxxx xxxxx
|
||||
x
|
||||
|
||||
xxxxxxxxx
|
||||
xxxxxx xxxxx xxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxx x
|
||||
xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
||||
xxxxxx xxxxx
|
||||
x
|
||||
xx [/pro] */
|
||||
|
||||
@Override
|
||||
public final SelectImpl union(Select<? extends R> select) {
|
||||
return new SelectImpl(getDelegate().union(select));
|
||||
|
||||
@ -163,6 +163,10 @@ class SelectQueryImpl<R extends Record> extends AbstractResultQuery<R> implement
|
||||
private ForUpdateMode forUpdateMode;
|
||||
private int forUpdateWait;
|
||||
private boolean forShare;
|
||||
/* [pro] xx
|
||||
xxxxxxx xxxxxxx xxxxxxxxxxxxxxxx
|
||||
xxxxxxx xxxxxxx xxxxxxxxxxxxx
|
||||
xx [/pro] */
|
||||
private final TableList from;
|
||||
private final ConditionProviderImpl condition;
|
||||
private final ConditionProviderImpl connectBy;
|
||||
@ -486,6 +490,18 @@ class SelectQueryImpl<R extends Record> extends AbstractResultQuery<R> implement
|
||||
}
|
||||
}
|
||||
|
||||
/* [pro] xx
|
||||
xx xxxxxxx xxx xxxxxx x xxx xxxxxx xxxx xxxxx xxxxxx x xxxx xxxx xxxx xxxxxxx
|
||||
xxxx xx xxxxxxxxxxxxxxxxx x
|
||||
xxxxxxxxxxxxxxxxxxxxxxxxx
|
||||
xxxxxxxxxxxxxx xxxxx xxxxxxxxx
|
||||
x
|
||||
xxxx xx xxxxxxxxxxxxxx x
|
||||
xxxxxxxxxxxxxxxxxxxxxxxxx
|
||||
xxxxxxxxxxxxxx xxxx xxxxxxx
|
||||
x
|
||||
xx [/pro] */
|
||||
|
||||
// [#1952] SQL Server OPTION() clauses as well as many other optional
|
||||
// end-of-query clauses are appended to the end of a query
|
||||
if (!StringUtils.isBlank(option)) {
|
||||
@ -1335,6 +1351,20 @@ class SelectQueryImpl<R extends Record> extends AbstractResultQuery<R> implement
|
||||
this.forUpdateWait = 0;
|
||||
}
|
||||
|
||||
/* [pro] xx
|
||||
xxxxxxxxx
|
||||
xxxxxx xxxxx xxxx xxxxxxxxxxxxxxxxxxxx x
|
||||
xxxxxxxxxxxxxxxxxxxx x xxxxx
|
||||
xxxxxxxxxxxxxxxxx x xxxxxx
|
||||
x
|
||||
|
||||
xxxxxxxxx
|
||||
xxxxxx xxxxx xxxx xxxxxxxxxxxxxxxxx x
|
||||
xxxxxxxxxxxxxxxxxxxx x xxxxxx
|
||||
xxxxxxxxxxxxxxxxx x xxxxx
|
||||
x
|
||||
xx [/pro] */
|
||||
|
||||
@Override
|
||||
public final List<Field<?>> getSelect() {
|
||||
return getSelect1();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user