About SELECT

41-50 of 200Refresh
Forum
21

Selecting random rows

Hello is there way to get random rows? Functions like rand(), random(), newid() doesn't work ;/ for example: em.createQuery("SELECT s FROM StawkaVat s ORDER BY rand()").setMaxResults(5).getResultList(); gives exception: Exception in thread "AWT-EventQueue-0" [ObjectDB 2.5.6_02] SELECT s FROM
Forum
21

A nested SELECT

Hello. I have a query UPDATE Look l SET l.partlySold = FALSE WHERE (SELECT count(a) FROM l.things a WHERE a.thing.status != :status) <= 1 which doesn't work: "Unexpected query token 'SELECT'". Does ObjectDB support queries like this? Thanks. Nested queries (issue #11) is currently not supported
Issue
21

NullpointerException at a normal select

When I run the following code: EntityManager em = getEm(); Customer result = null; try {     logger.debug("Ident: "+ident);     result = em.createQuery("Select c from Customer c where c.identifier=:id", Customer.class).setParameter("id", ident).getSingleResult(); } catch (javax.persistence
Forum
21

Performance in SELECT statement

has around 30.000 rows) Example query looks like : String strSelect = "SELECT e FROM TestEntity
Issue
21

selective update not working

we try to optimize for our queries and tried a selective update, but in explorer it just shows query execution error:   UPDATE ObjectNode o SET o.state = 5 where o.classIdentifier = '(MA)' and o.objectNameUpper = 'DMU200P2' and o.state = 0 and o.type = 1 and o.parentNode.classIdentifier = '(NC
Forum
20

Class fields selection to store

Class fields selection to store
Forum
20

Selective merge/cascade of detatched entity

Selective merge/cascade of detatched entity
Result
20

E-select.png

E-select.png
Result
20

select-run-config.png

select-run-config.png
Manual
20

Paths and Types in JPQL and Criteria API

identification variables and SELECT result variables. Parameters - when instances of these classes are assigned ... through a NULL value The following query retrieves country names with their capital city names: SELECT ... of all the entity objects in the database, excluding Country entity objects: SELECT COUNT(e) FROM