Home » Search

About parameters

1-10 of 200Refresh
Manual
290

Query Parameters in JPA

Query parameters enable the definition of reusable queries. Such queries can be executed with different parameter values to retrieve different results. Running the same query multiple times with different parameter values (arguments) is more efficient than using a new query string for every query
JPA Doc
68

javax.persistence.Parameter

javax.persistence Interface Parameter Subinterfaces: ParameterExpression Type for query parameter objects. Since: JPA 2.0 See Also: Query TypedQuery Learn how to define and use JPA/JPQL queries in Chapter 4 of the ObjectDB/JPA manual. String getName() Return the parameter name, or null
JDO Doc
66

addSubquery(sub, variableDeclaration, candidateCollectionExpression, parameters)

 candidateCollectionExpression,   String... parameters ) Add a subquery to this query. A subquery ... this method. The query parameter instance is unmodified as a result of the addSubquery or subsequent execution ... copied include the candidate class, filter, parameter declarations, variable declarations, imports
JDO Doc
66

declareParameters(parameters)

Method javax.jdo.Query void declareParameters(   String parameters ) Declare the list of parameters query execution. The parameter declaration is a String containing one or more query parameter declarations separated with commas. Each parameter named in the parameter declaration must be bound
JDO Doc
66

executeWithArray(parameters)

Method javax.jdo.Query Object executeWithArray(   Object... parameters ) Execute the query and return the filtered Collection. The execution of the query obtains the values of the parameters and matches them against the declared parameters in order. The names of the declared parameters are ignored
JDO Doc
65

executeWithMap(parameters)

Method javax.jdo.Query Object executeWithMap(   Map parameters ) Execute the query and return the filtered Collection. The query is executed with the parameters set by the Map values. Each Map entry consists of a key which is the name of the parameter in the declareParameters method, and a value
JDO Doc
65

addSubquery(sub, variableDeclaration, candidateCollectionExpression, parameters)

 candidateCollectionExpression,   Map parameters ) Add a subquery to this query. The Map version of the method treats the key of each map entry as the name of the parameter in the subquery, with or ... expression is the empty String for either the parameter or the value of the String[], or for any map key
JDO Doc
64

addSubquery(sub, variableDeclaration, candidateCollectionExpression, parameter)

 candidateCollectionExpression,   String parameter ) Add a subquery to this query. The String version of the method binds the named expression to the parameter implictly or explicitly declared in the subquery. Parameters: sub - the subquery to add to this Query variableDeclaration - the name
JPA Doc
64

parameter(paramClass, name)

Method javax.persistence.criteria.CriteriaBuilder ParameterExpression parameter(   Class paramClass,   String name ) Create a parameter expression with the given name. Parameters: paramClass - parameter class name - name that can be used to refer to the parameter Returns: parameter expression Since: JPA 2.0
JPA Doc
64

getName()

Method javax.persistence.Parameter String getName() Return the parameter name, or null if the parameter is not a named parameter or no name has been assigned. Returns: parameter name Since: JPA 2.0