ObjectDB ObjectDB

Internal Website Search

71-80 of 200 resultsRefresh
13

Possible issue with timestamps

.getTransaction().commit();              TypedQuery<Long> query = em.createQuery("SELECT count(c) FROM CDI c", Long.class);         Long cdiCount = query.getSingleResult();         assertEquals(22 ... .creationDate > {ts '2012-03-29 00:00:00'} and c.creationDate < {ts '2012-03-29 00:59:00'}", Long
13

Date field Index is corrupted due to time change

.createQuery("SELECT COUNT(r) FROM DateTime AS r");         em.getTransaction().begin();         Long r = (Long) q.getSingleResult();         em.getTransaction().commit();                 System.out.println ... ().begin();         r = (Long) q.getSingleResult();         em.getTransaction().commit
13

Error 363 - Failed to read value of inverse relationship

= GenerationType.AUTO) private long id; @ManyToOne(optional=false) private ETown town ... implements Serializable { private static final long serialVersionUID = 1L; @Id @GeneratedValue private Long id; private int permission = 0, activePermission = 0; private
12

Is it possible to remove parent/child entities without refresh?

  private long id;   @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy ... (this);    children.put(child.getChildName(), child);   }   public long getId() {    return id;   }   public void setId(long id) {    this.id = id;   } } @Entity public static class ChildEntity
12

Visibility of changes in Transaction is not visible to a JPA QL Query

to see that they have been added long newTotal = -1;   try {    InitialContext context = new ... = (SLSBObjDbRemote) context      .lookup("SLSBObjDb");    long oldAmount = bean.countItems();    bean.addItems ... go to count them; TypedQuery<Long> q = em.createQuery("SELECT COUNT(x) FROM Item x", Long.class
12

Wrong data stored in time only fields

();         Query q = em.createQuery("SELECT COUNT(r) FROM DateTime AS r");         Long r = (Long ... static Date roundDownDateTime(Date dateTime) {         long dateTimeMs = dateTime.getTime();         long reminderMs  = dateTimeMs % 1000;         dateTimeMs -= reminderMs;         return new
2

After using the enhancer, Lazy loaded collections are no longer loading. They are set as null

Account extends AbstractEntity implements IAbstractEntity<Long> { @Id @Column(name = "account_id") @GeneratedValue(strategy= GenerationType.TABLE) protected Long id; @Override public Long getId() { return id; } @Override public void setId
2

count(x)

Method javax.persistence.criteria.CriteriaBuilder Expression<Long> count( Expression<?> x ) Create an aggregate expression applying the count operation. Parameters: x - expression representing input value to count operation Returns: count expression Since: JPA 2.0
2

countDistinct(x)

Method javax.persistence.criteria.CriteriaBuilder Expression<Long> countDistinct( Expression<?> x ) Create an aggregate expression applying the count distinct operation. Parameters: x - expression representing input value to count distinct operation Returns: count distinct expression Since: JPA 2.0
0

replacingLongField(pc, field)

Method javax.jdo.spi.StateManager long replacingLongField( PersistenceCapable pc, int field ) The replacement value of the field in the calling instance. Parameters: pc - the calling PersistenceCapable instance field - the field number Returns: the new value for the field Since: JDO 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