ObjectDB ObjectDB

Internal Website Search

11-20 of 69 resultsRefresh
144

A bidirectional OneToOne association with a shared primary key

Hi, In Hibernate, it is possible (using Hibernate specific annotations) to define a bidirectional @OneToOne association that has a shared primary key, example: http://fruzenshtein.com/bidirectional ... Voumard No annotations are required by ObjectDB (you may use @OneToOne annotations with no mappedBy
24

Detached Entity Objects

): @Entity class Employee { : @OneToOne(cascade=CascadeType.DETACH) private Address ... ): @Entity class Employee { : @OneToOne(cascade=CascadeType.MERGE) private Address
24

Retrieving JPA Entity Objects

specifying FetchType.LAZY in either @OneToOne or @ManyToOne annotations (currently ObjectDB does not ... { : @OneToOne(cascade=CascadeType.REFRESH) private Address address; : } In
17

Storing JPA Entity Objects

{ : @OneToOne(cascade=CascadeType.PERSIST) private Address address; : } In
11

javax.persistence.PrimaryKeyJoinColumn

to a primary table; and it may be used in a OneToOne mapping in which the primary key ... OneToOne String columnDefinition (Optional) The SQL fragment that is used when generating the DDL ... . This should not be specified for a OneToOne primary key association. Defaults to the generated SQL to create
11

javax.persistence.JoinColumn

getOrders() {return orders;} Since: JPA 1.0 See Also: ManyToOne OneToMany OneToOne JoinTable ... . If the join is for a OneToOne or ManyToOne mapping using a foreign key mapping strategy, the foreign ... entity. If the join is for a ManyToMany mapping or for a OneToOne or bidirectional ManyToOne
7

JoinColumn.name

Annotation Element javax.persistence.JoinColumn String name (Optional) The name of the foreign key column. The table in which it is found depends upon the context. If the join is for a OneToOne or ... is for a ManyToMany mapping or for a OneToOne or bidirectional ManyToOne/OneToMany mapping using a join table
7

JoinColumn.table

of the applicable entity. Default: If the join is for a OneToOne or ManyToOne mapping using a foreign ... of the target entity. If the join is for a ManyToMany mapping or for a OneToOne or bidirectional
5

PrimaryKeyJoinColumn.name

for the referencing entity (OneToOne mapping). Default value: "" Since: JPA 1.0
5

PrimaryKeyJoinColumn.columnDefinition

Annotation Element javax.persistence.PrimaryKeyJoinColumn String columnDefinition (Optional) The SQL fragment that is used when generating the DDL for the column. This should not be specified for a OneToOne primary key association. Defaults to the generated SQL to create a column of the inferred type. Default value: "" Since: JPA 1.0

Getting Started

ObjectDB is very easy to use. Follow the Getting Started Tutorial and the Quick Tour manual chapter and in minutes you may be able to write and run first Java programs against ObjectDB.

Prior knowledge or experience in database programming (SQL, JDBC, ORM, JPA, etc.) is not required, but some background in using the Java language is essential.

Need Help?

  1. Search ObjectDB website
  2. Read the FAQ
  3. Follow the Tutorials
  4. View or post in the forum
  5. Search or file an issue
  6. Contact support