Guten Tag Lukas Eder,
am Samstag, 6. Juni 2020 um 10:28 schrieben Sie:
> jOOQ 3.10 introduced a configuration <recordsImplementingRecordN/>
> https://github.com/jOOQ/jOOQ/issues/6072
That option is enabled, explicitly disabling it results in different
results of the generator breaking things additionally.
> [...]Otherwise, what's the type of your RdQueryBuilder.CTE_NAME_RE_IDS?
It's really only a name:
> private static final Name CTE_NAME_RE_IDS = DSL.name("real_estate_ids");
The corresponding column, indentation is by me:
> public final TableField<RealEstateRecord, IntegerID = createField
> (
> DSL.name("id"),
> org.jooq.impl.SQLDataType.INTEGER.nullable(false).defaultValue
> (
> org.jooq.impl.DSL.field
> (
> "nextval('real_estate_id_seq'::regclass)",
> org.jooq.impl.SQLDataType.INTEGER
> )
> ),
> this,
> ""
> );
The overloads in "Field":
> Condition in(Collection<?> values);
> Condition in(Result<? extends Record1<T>> result);
> Condition in(T... values);
> Condition in(Field<?>... values);
> Condition in(Select<? extends Record1<T>> query);
The following works, but is obviously wrong:
> .where(REAL_ESTATE.ID.in((Field<?>)
> DSL.selectFrom(RdQueryBuilder.CTE_NAME_RE_IDS))
Every other cast seems to fail with Java trying to use the overload
for "in(Collection)". I really only want an "in(SELECT * FROM ...)"
and other more verbose statements don't work as well:
> .where(REAL_ESTATE.ID.in(DSL.select(DSL.asterisk()).from("").where(DSL.trueCondition()))
> .where(REAL_ESTATE.ID.in(this.getDbConn().getJooq().select(DSL.asterisk()).from("").where(DSL.trueCondition()))
Isn't that pretty much what the official docs have as example as well?
https://www.jooq.org/doc/3.13/manual/sql-building/table-expressions/nested-selects/
Mit freundlichen Grüßen,
Thorsten Schöning
--
Thorsten Schöning E-Mail: [email protected]
AM-SoFT IT-Systeme http://www.AM-SoFT.de/
Telefon...........05151- 9468- 55
Fax...............05151- 9468- 88
Mobil..............0178-8 9468- 04
AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln
AG Hannover HRB 207 694 - Geschäftsführer: Andreas Muchow
--
You received this message because you are subscribed to the Google Groups "jOOQ
User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jooq-user/1844759065.20200606151834%40am-soft.de.