About int

11-20 of 200Refresh
Manual
19

Defining a JPA Entity Class

; @Entity public class Point { // Persistent Fields: private int x; private int y; // Constructor: Point (int x, int y) { this.x = x; this.y = y; } // Accessor Methods: public int getX() { return this.x; } public int getY() { return this.y
Manual
17

JPA Primary Key

: boolean, byte, short, char, int, long, float, double. Equivalent wrapper classes from package java ... (ProjectId.class) public class Project { @Id int departmentId; @Id long projectId ... fields and its objects can represent primary key values: Class ProjectId { int departmentId
JDO Doc
15

javax.jdo.spi.StateManager

getBooleanField( PersistenceCapable pc, int field, boolean currentValue) Return the value ... Since: JDO 1.0 byte getByteField( PersistenceCapable pc, int field, byte currentValue) Return ... value for the field Since: JDO 1.0 char getCharField( PersistenceCapable pc, int field, char
Manual
13

Numbers in JPQL and Criteria Queries

on an int value and a double value is double. The ABS Function The ABS function removes the minus sign from ... in Java (e.g. for int and long operands the MOD function returns a long value). The SQRT Function ... The above examples demonstrate only integer expressions, but all the numeric types (byte, short, int, long, float
Manual
13

Index Definition

indexedField1; @Index(unique="true") int indexedField2; // unique @Index(name="i3") int indexedField3 ... a value of one of the following persistable types: Primitive types: boolean, byte, short, char, int, long
Manual
13

Database Schema Evolution

int to Date) the fields are not considered as matching and the new field is initialized ... to any numeric type. In this context numeric types are: byte, short, char, int, long, float, double ... long as the elements are convertible (e.g. from int[] to ArrayList). From any object to any
Manual
10

DELETE Queries in JPA/JPQL

method:   int deletedCount = em.createQuery("DELETE FROM Country").executeUpdate ... = em.createQuery(       "DELETE FROM Country c WHERE c.population < :p");   int deletedCount = query.setParameter(p, 100000).executeUpdate();
Manual
10

UPDATE SET Queries in JPA/JPQL

.createQuery(       "UPDATE Country SET population = 0, area = 0");   int updateCount = em.executeUpdate ... * 11 / 10 " +       "WHERE population < :p");   int updateCount = query.setParameter(p, 100000).executeUpdate();
Manual
10

UPDATE SET Queries in JPA/JPQL [2011-11-22]

.createQuery(       "UPDATE Country SET population = 0, area = 0");   int updateCount = em.executeUpdate ... * 11 / 10 " +       "WHERE c.population < :p");   int updateCount = query.setParameter(p, 100000).executeUpdate();
Manual
10

Storing JPA Entity Objects

can be used to save memory in large transactions: em.getTransaction().begin(); for (int i = 1; i ... .getTransaction().begin(); for (int i = 1; i <= 1000000; i++) { Point point = new Point(i, i