referencedOn

infix fun <REF : Any> referencedOn(column: Column<REF>): Reference<ID, T, REF>

Registers a reference as a field of the child entity class, which returns a parent object of this EntityClass.

The reference should have been defined by the creation of a column using reference() on the child table.

R2DBC counterpart of JDBC's referencedOn. Returns a Reference that delegates to a suspending Accessor — JDBC's version returns the entity directly via a synchronous lookup.


infix fun referencedOn(table: IdTable<*>): Reference<ID, T, Any>

Composite-FK form of referencedOn. R2DBC counterpart of JDBC's referencedOn(IdTable<*>).

Resolves the composite foreign-key constraint on table that points at this entity's primary key and binds the reference's first FK column as the delegate.