docs/api/exposed-dao/org.jetbrains.exposed.v1.dao/-entity-class/optional-referenced-on.html
infix fun <REF : Any> optionalReferencedOn(column: Column<REF?>): OptionalReference<REF, ID, T>
Registers an optional 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 either optReference() or reference().nullable() on the child table.
org.jetbrains.exposed.v1.tests.shared.entities.EntityTests.Boardorg.jetbrains.exposed.v1.tests.shared.entities.EntityTests.Postsorg.jetbrains.exposed.v1.tests.shared.entities.EntityTests.Post
infix fun optionalReferencedOn(table: IdTable<*>): OptionalReference<Any, ID, T>
Registers an optional 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 foreign key constraint on the child table, by using foreignKey().
org.jetbrains.exposed.v1.tests.shared.entities.CompositeIdTableEntityTest.Publisherorg.jetbrains.exposed.v1.tests.shared.entities.CompositeIdTableEntityTest.Officesorg.jetbrains.exposed.v1.tests.shared.entities.CompositeIdTableEntityTest.Office
Generated by Dokka © 2026 Copyright