Home » Search

About point

1-10 of 200Refresh
Manual
103

Defining a JPA Entity Class

To be able to store Point objects in the database using JPA we need to define an entity class ... to serializable classes, which are marked as having the ability to be serialized. The Point Entity Class The following Point class, which represents points in the plane, is marked as an entity class
Manual
53

CRUD Database Operations with JPA

code fragment stores 1,000 Point objects in the database: em.getTransaction().begin(); for (int i = 0; i < 1000; i++) { Point p = new Point(i, i); em.persist(p); } em ... ) require an active transaction. In the example above, every Point object is first constructed as
Tutorial
44

Step 3: Add a Main Class

In this step we will add a main class to the project with code that will store Point objects in ... = Persistence.createEntityManagerFactory("$objectdb/db/points.odb"); EntityManager em = emf.createEntityManager(); // Store 1000 Point objects in the database: em
Tutorial
44

Step 3: Add a Main Class

to store Point objects in the database and then retrieve them from the database. Use copy and paste ... ("$objectdb/db/points.odb"); EntityManager em = emf.createEntityManager(); // Store 1000 Point objects in the database: em.getTransaction().begin(); for (int i = 0; i
Manual
32

Storing JPA Entity Objects

<= 1000000; i++) { Point point = new Point(i, i); em.persist(point); if ((i ... . Therefore, holding 1,000,000 managed Point instances in the persistence context might consume ... .getTransaction().begin(); for (int i = 1; i <= 1000000; i++) { Point point = new Point(i, i
Manual
28

Index Definition

execution. Indexes are especially efficient in lookup and range queries: SELECT p FROM Point p WHERE p.x = 100 SELECT p FROM Point p WHERE p.x BETWEEN 50 AND 80 SELECT p FROM Point p WHERE p.x >= 50 ... enables quick execution of the following queries: SELECT p FROM Point p WHERE p.x = 100 AND p.y = 100
Tutorial
28

Step 2: Define a JPA Entity Class

package name. Enter Point as the class name - use exactly that case sensitive class name. Click Finish ... class Point implements Serializable { private static final long serialVersionUID = 1L ... Point() { } Point(int x, int y) { this.x = x; this.y = y
Tutorial
28

Step 2: Define a JPA Entity Class

) and selecting New > Java Class... Enter Point as the class name - use exactly that case sensitive ... .Serializable; import javax.persistence.*; @Entity public class Point implements Serializable ... id; private int x; private int y; public Point() { } Point(int x, int
Manual
23

BIRT/ODA ObjectDB Driver

. Enter data source name (e.g. ObjectDB Points) and click Next. Specify an ObjectDB connection url - either embedded (e.g. c:\points.odb) or client-server (e.g. objectdb://localhost/points.odb;user=admin ... (e.g. ObjectDB Points).  Enter a data set name (e.g. Points by X) and click Next. Entry a JPQL or
Tutorial
23

Step 4: Create an ObjectDB Data Set

Points).  Enter a data set name (e.g. Points by X) and click Next. The database in this tutorial contains Point entity objects. We will use a simple JPQL query that retrieves points with x value in a specified range: SELECT p.x as x, p.y as y FROM Point p WHERE p.x BETWEEN :low AND :high Use copy