Examples of declareParameters()


Examples of javax.jdo.Query.declareParameters()

    try {
      openTransaction();
      LOG.debug("Executing listDatabaseGrants");
      Query query = pm.newQuery(MDBPrivilege.class,
          "database.name == t1");
      query.declareParameters("java.lang.String t1");
      List<MDBPrivilege> mSecurityDBList = (List<MDBPrivilege>) query
          .executeWithArray(dbName);
      LOG.debug("Done executing query for listDatabaseGrants");
      pm.retrieveAll(mSecurityDBList);
      success = commitTransaction();
View Full Code Here

Examples of org.apache.openjpa.kernel.Query.declareParameters()

    public void testQuery() {
        EntityManager pm = _pmf.createEntityManager();
        //FIXME jthomas - partly commented
        //Query q = pm.newQuery(ByteArrayPKPC.class, "pk == bytes");
        Query q =null;//= pm.newQuery(ByteArrayPKPC.class, "pk == bytes");
        q.declareParameters("byte[] bytes");
        //FIXME jthomas - no execute for byte
        //Collection results = (Collection) q.execute(new byte[]{ 1, 2 });
        Collection results =null;//= (Collection) q.execute(new byte[]{ 1, 2 });
        assertEquals(1, results.size());
        ByteArrayPKPC2 child = (ByteArrayPKPC2) results.iterator().next();
View Full Code Here

Examples of org.springframework.jdbc.core.simple.SimpleJdbcCall.declareParameters()

    ctrlConnection.setReturnValue(mockCallable);

    replay();

    SimpleJdbcCall adder = new SimpleJdbcCall(mockDataSource).withProcedureName("add_invoice");
    adder.declareParameters(new SqlParameter("amount", Types.INTEGER),
        new SqlParameter("custid", Types.INTEGER),
        new SqlOutParameter("newid", Types.INTEGER));
    Number newId = adder.executeObject(Number.class, new MapSqlParameterSource()
        .addValue("amount", amount)
        .addValue("custid", custid));
View Full Code Here

Examples of org.xorm.query.QueryImpl.declareParameters()

            else {
                // Append this owner param to the existing parameters
                parameters += ", " + ownerClassName + " owner";
            }
            logger.fine("Modified Parameters: " + parameters);
            query.declareParameters(parameters);

            if (mapping.getVariables() != null) {
                query.declareVariables(mapping.getVariables());
            }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.