ObjectDB Database Search
1-50 of 113 resultsSELECT clause (JPQL / Criteria API) The ability to retrieve managed entities is a key advantage of JPQL. For example , the following ... . Projection of path expressions JPQL queries can also return results that are not entities. For example ... the FROM clause. Nested path expressions are also supported. For example , the following query retrieves | |
JPA Entity Fields-final entity field is persistent by default unless specified otherwise (for example , by using ... , such as Hibernate, or for changing default field settings. For example : @Entity public class ... ( mappedBy ="department") Set employees; } The mappedBy element in the preceding example specifies | |
Setting and Tuning of JPA Queries efficient result paging. For example , if each page displays pageSize results and pageId represents ... to all result objects that the query retrieves. For example , the following code sets a pessimistic WRITE ... . For example , setting a query hint on an EntityManager affects all queries that are created by | |
Storing JPA Entities. Referenced entities If, however, the Address class in the previous example is an entity class ... ) private Address address; : } In the preceding example , the Employee entity class contains ... a separate persist call. Cascading can continue recursively, for example , to entities that the Address | |
Database Transaction Replayer file, such as my.odb in the example above. ObjectDB automatically locates the corresponding backup ... . You can also run the Replayer up to a specified transaction. For example : $ java -cp objectdb.jar com | |
jakarta.persistence.Convert to prefix the name of the attribute of the key or value type that is converted. Example 1: Convert ... ) boolean fullTime; ... } Example 2: Auto-apply conversion of a basic attribute @Converter(autoApply ... ; } Example 3: Disable conversion in the presence of an autoapply converter @Convert | |
JPA Criteria Query Expressions how whitespace should be trimmed ( LEADING , TRAILING , or BOTH ). For more details and examples , see the Query Expressions section in the ObjectDB manual. | |
JPA Lifecycle Events Callback methods are user-defined methods that are attached to entity lifecycle events. JPA invokes these methods automatically when the corresponding events occur. Internal callback methods Internal callback methods are defined within an entity class. For example , the following entity class | |
Apache License, Version 2.0, January 2004 indicated by a copyright notice that is included in or attached to the work (an example is provided | |
Server Configuration the connection URL is resolved relative to the data path. For example , objectdb://localhost/my/db | |
JPA Named Queries Annotations, cache usage, or fetch graphs. For details and examples , see the JPA Named Queries section | |
Guestbook example from tutorial does not work. you for your quick reply. But thats a maven example . If i place the object-jee.jar to th /Web-inf/lib ... examples have been updated and tested successfully with TomEE 1.7.2 and ObjectDB 2.6.2_02. support Support | |
jakarta.persistence.MapKeyClass annotation is not used when MapKeyClass is specified and vice versa. Example 1: @Entity public class Item ... images; // map from image name to image filename ... } Example 2: // MapKeyClass and target type ... ; ... } Example 3: @Entity public class Company { @Id int id; ... @OneToMany(targetEntity = com | |
jakarta.persistence.MapKeyJoinColumn and the default values apply. Example 1: @Entity public class Company { @Id int id; ... @OneToMany ... ") Map organization; } Example 2: @Entity public class VideoStore { @Id int id; String name; Address ... ; ... } Example 3: @Entity public class Student { @Id int studentId; ... @ManyToMany // students and courses | |
jakarta.persistence.ManyToMany notation is the name of the respective embedded field or property. Example 1: // In Customer class ... PhoneNumber class: @ManyToMany(mappedBy = "phones") public Set getCustomers() { return customers; } Example ... , mappedBy = "phones") public Set getCustomers() { return customers; } Example 3: // In Customer class | |
jakarta.persistence.Embeddable or property of an embeddable class which is not persistent. Example 1: @Embeddable public class ... ; ... } Example 2: @Embeddable public class PhoneNumber { protected String areaCode; protected String ... PhoneServiceProvider { @Id protected String name; ... } Example 3: @Embeddable public class Address { protected | |
jakarta.persistence.GeneratedValue primary keys is not supported. Example 1: @Id @GeneratedValue(strategy = SEQUENCE, generator = "CUST_SEQ") @Column(name = "CUST_ID") public Long getId() { return id; } Example 2: @Id @GeneratedValue | |
jakarta.persistence.Lob it defaults to CLOB ; for all other types it defaults to BLOB . Example 1: @Lob @Basic(fetch = LAZY) @Column(name = "REPORT") protected String report; Example 2: @Lob @Basic(fetch = LAZY) @Column(name | |
jakarta.persistence.JoinColumn and the default values apply. Example : @ManyToOne @JoinColumn(name = "ADDR_ID") public Address getAddress() { return address; } Example : unidirectional one-to-many association using a foreign key mapping // In | |
jakarta.persistence.MapKeyColumn of the following: the name of the referencing relationship field or property; " _ "; " KEY ". Example : @Entity ... is parameterized by length, for example , varchar or varbinary types. Default: 255 Since: Jakarta | |
jakarta.persistence.MapKey used when MapKey is specified and vice versa. Example 1: @Entity public class Department ... = "dept_id") public Department getDepartment() { ... } ... } Example 2: @Entity public class Department | |
jakarta.persistence.ManyToOne with the dot notation is the name of the respective embedded field or property. Example 1: @ManyToOne(optional ... getCustomer() { return customer; } Example 2: @Entity public class Employee { @Id int id; @Embedded JobInfo | |
jakarta.persistence.EmbeddedId. Relationship mappings defined within an embedded primary key type are not supported. Example 1: @Entity ... empName, Date birthDay) {} Example 2: @Embeddable public class DependentId { String name | |
Update Entity references if we change the type of an entity. As example (like in the attached example ): We have an EntityA that have a reference to an EntityB. But now we introduced as example a new Entity NewKindOfEntityB. And we have a defined logic ... example to demonstrate the scenario is attached. btc_es BTC EmbeddedSystems The example contained | |
Problem with byte arrays in JDO - internal exception; import javax.jdo.Query; import spiffy.test.model. Example ; /** * * @author steve */ public class ... (); Query query = pm.newQuery( Example .class); query.deletePersistentAll(); pm.currentTransaction().commit(); pm.currentTransaction().begin(); Example example1 = new Example (); example1.setId(1); example1 | |
jakarta.persistence.Id is assumed to be the name of the primary key property or field. Example : @Id public Long getId | |
jakarta.persistence.IdClass to be annotated. Example : @IdClass(EmployeePK.class) @Entity public class Employee { @Id String empName | |
jakarta.persistence.ForeignKey the target database for foreign key constraint creation. For example , it might be similar to the following | |
jakarta.persistence.JoinTable) using an underscore. Example : @JoinTable( name = "CUST_PHONE", joinColumns = @JoinColumn(name = "CUST_ID | |
jakarta.persistence.Inheritance is used. Example : @Entity @Inheritance(strategy = JOINED) public class Customer { ... } @Entity public | |
jakarta.persistence.JoinColumns specify both name and referencedColumnName . Example : @ManyToOne @JoinColumns({ @JoinColumn(name | |
jakarta.persistence.MapKeyEnumerated, the enumerated type is assumed to be ORDINAL . Example : public enum ProjectStatus {COMPLETE, DELAYED | |
jakarta.persistence.MapKeyTemporal.Map in conjunction with the ElementCollection , OneToMany , or ManyToMany annotation. Example | |
jakarta.persistence.MapsId specified. In this example , the parent entity has simple primary key: @Entity public class Employee | |
jakarta.persistence.MappedSuperclass. Example : Concrete class as a mapped superclass @MappedSuperclass public class Employee { @Id | |
jakarta.persistence.ConstructorResult is retrieved for the constructed object. Example : Query q = em.createNativeQuery( "SELECT c.id, c.name | |
jakarta.persistence.ColumnResult can be included in the query result by specifying this annotation in the metadata. Example : Query q = em | |
jakarta.persistence.Embedded may be used to override mappings declared or defaulted by the embeddable class. Example : @Embedded | |
jakarta.persistence.DiscriminatorColumn to DiscriminatorType.STRING . Example : @Entity @Table(name = "CUST") @Inheritance(strategy = SINGLE_TABLE | |
jakarta.persistence.ElementCollection. The CollectionTable annotation specifies a mapping to a database table. Example : @Entity public class | |
jakarta.persistence.DiscriminatorValue, should be specified for each concrete entity class in the hierarchy. Example : @Entity @Table(name = "CUST | |
jakarta.persistence.EntityResult. Example : Query q = em.createNativeQuery( "SELECT o.id, o.quantity, o.item, " + "i.id, i.name, i | |
jakarta.persistence.FetchType is permitted to eagerly fetch data for which the LAZY strategy hint has been specified. Example | |
jakarta.persistence.FieldResult Jakarta Persistence (JPA) Annotation Type jakarta.persistence.FieldResult Implemented Interfaces: Annotation Used in conjunction with the EntityResult annotation to map columns specified in the SELECT list of a SQL query to the properties or fields of an entity class. Example : Query q = em | |
jakarta.persistence.Enumerated to be EnumType.ORDINAL . Example : public enum EmployeeStatus {FULL_TIME, PART_TIME, CONTRACT} public enum | |
jakarta.persistence.EnumeratedValue. Example : enum Status { OPEN(0), CLOSED(1), CANCELLED(-1); @EnumeratedValue final int intValue; Status(int | |
Explorer in 2.3 to enter a Java expression into a field. For example , suppose you have a User entity with a password ... , on the other hand, is quite useful during development when I want to see examples of data, but I don't ... only interested in seeing an example of the data, rather than all of it. For #5 - I was talking | |
General Performance Issues Illustrated with a Specific Method in the future if you follow the posting instruction and post minimal examples (for example ... this thread now and start again with a clean thread and a minimal runnable example . See posting instructions and examples of other recent threads. Post again after isolating an issue to the minimum possible | |
[ODB1] Chapter 6 - Persistent Objects yet. Such an object ID is fixed on commit() . For example : pm.currentTransaction().begin(); Person ... with an assigned name, can be retrieved by using its name. For example , a root with the name ... of the direct interaction with the database, in order to make database programming easier. For example | |
combined index not used can be embedded at the end of the query text in the format [[name=value]]. For example : SELECT ... there is a significant waiting time in the above functionality queries are significantly slow, example ... -Georg Zwicker just to make clear: all queries are slow, not only the above example hgzwicker Hans |