About SELECT

11-20 of 200Refresh
JPA Doc
54

alias(name)

Method javax.persistence.criteria.Selection Selection alias(   String name ) Assigns an alias to the selection item. Once assigned, an alias cannot be changed or reassigned. Returns the same selection item. Parameters: name - alias Returns: selection item Since: JPA 2.0
JPA Doc
54

isCompoundSelection()

Method javax.persistence.criteria.Selection boolean isCompoundSelection() Whether the selection item is a compound selection. Returns: boolean indicating whether the selection is a compound selection Since: JPA 2.0
JPA Doc
52

select(expression)

Method javax.persistence.criteria.Subquery Subquery select(   Expression expression ) Specify the item that is to be returned as the subquery result. Replaces the previously specified selection, if any. Parameters: expression - expression specifying the item that is to be returned as
Manual
27

GROUP BY and HAVING clauses

clause in the query execution order is after the FROM and WHERE clauses, but before the SELECT ... to grouping by the GROUP BY clauses before arriving at the SELECT clause. GROUP BY as DISTINCT (no Aggregates) The following query groups all the countries by their first letter: SELECT SUBSTRING(c
Manual
26

Database Explorer

Embedded... command and select a local database file. To open a database in client-server mode select File > Open C/S Connection... and provide host, port, username and password for a client-server ... the tree). To open a new viewer window either write a query in the [Query] tabbed window or select
Manual
26

FROM clause (JPQL / Criteria API)

over all the Country objects in the database: SELECT c FROM Country AS c The AS keyword is optional, and the same query can also be written as follows: SELECT c FROM Country c By default, the name ... returns all the pairs of countries that share a common border: SELECT c1, c2 FROM Country c1, Country c2
Manual
26

ORDER BY clause (JPQL / Criteria API)

is at least one million people, ordered by the country name: SELECT c.name FROM Country c WHERE c.population > 1000000 ... clause produces objects for examination and the WHERE clause selects which objects to collect as results. Then the SELECT clause builds the results by evaluating the result expressions. Finally the results
Manual
24

WHERE clause (JPQL / Criteria API)

The WHERE clause adds filtering capabilities to the FROM-SELECT structure. It is essential in any JPQL query that retrieves selective objects from the database. Out of the four optional clauses ... , which is represented by the parameter p: SELECT c FROM Country c WHERE c.population > :p The FROM clause
Manual
21

JPA Query Structure (JPQL / Criteria)

and easier to use in Java. JPQL Query Structure As with SQL, a JPQL SELECT query also consists of up to 6 clauses in the following format: SELECT ... FROM ... [WHERE ...] [GROUP BY ... [HAVING ...]] [ORDER BY ...] The first two clauses, SELECT and FROM are required in every retrieval query
Manual
20

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