Examples of newQuery()


Examples of Express.services.BusinessClass.newQuery()

                if (this.getWindowInfo().getParentWindow() != null) {
                    currec = this.getWindowInfo().getParentWindow().getCurRec();
                }

                if ((this.getWindowInfo().getDataToDisplay() == ExpressClassWindow.DD_ASSOCIATED_RECORD) && currec != null) {
                    BusinessQuery qry = currec.newQuery();
                    Array_Of_QueryAttrMap<QueryAttrMap> fks = qry.getForeignAttrMap(this.getWindowInfo().getAssocNum());
                    if (fks != null && fks.size() > 0 && fks.get(0).getLocal() == 1) {
                        //
                        // Record class contains a foreign key that references primary key
                        // in 'currec' class (Primary keys always begin at ATTR_ number=1).
View Full Code Here

Examples of com.esri.gpt.control.webharvest.client.arcgis.ArcGISQueryBuilder.newQuery()

        public void onIterationException(Exception ex) {
          LOGGER.log(Level.SEVERE, "Error iterating through AGS resources.", ex);
        }
      }, source);
     
      Query newQuery = qb.newQuery(new CommonCriteria());
      Result result = newQuery.execute();

      this.destination.getConnection().generateToken();
     
      Iterable<IServiceInfoProvider> records = new ServiceInfoProviderAdapter(new FlatResourcesAdapter(result.getResources()));
View Full Code Here

Examples of com.gemstone.gemfire.cache.query.QueryService.newQuery()

  @Override
  @SuppressWarnings("unchecked")
  public <E> SelectResults<E> find(final String queryString, final Object... params) throws InvalidDataAccessApiUsageException {
    try {
      QueryService queryService = lookupQueryService(getRegion());
      Query query = queryService.newQuery(queryString);
      Object result = query.execute(params);

      if (result instanceof SelectResults) {
        return (SelectResults<E>) result;
      }
View Full Code Here

Examples of com.ipc.oce.OCApp.newQuery()

   */
  public OCDocumentRef findByNumber2(String number, Date docDate) throws JIException {
    OCApp instance = OCApp.getInstance(getAssociatedSessionID());
   
    // prepare query
    OCQuery query = instance.newQuery(
        "SELECT Doc.Ref FROM Document."
        + managerName
        + " AS Doc WHERE Doc.Number = &NUM_A AND Doc.Date = &DATE_A");
   
    // set parameters
View Full Code Here

Examples of javax.jdo.PersistenceManager.newQuery()

            "(SELECT AVG(e.weeklyhours) FROM " + Employee.class.getName() + " e)";

        // create subquery instance using different pm
        PersistenceManager newPM =
            pm.getPersistenceManagerFactory().getPersistenceManager();
        Query sub = newPM.newQuery(Employee.class);
        sub.setResult("avg(this.weeklyhours)");

        Query apiQuery = pm.newQuery(Employee.class);
        apiQuery.setFilter("this.weeklyhours> averageWeeklyhours");
        apiQuery.addSubquery(sub, "double averageWeeklyhours", null);
View Full Code Here

Examples of javax.jdo.PersistenceManager.newQuery()

      // First get the expired contracts that have not been archived yet
      // Get the prices and archive them
      query = "SELECT FROM " + Contract.class.getName() + " WHERE expiryDate>0 && archived==false ORDER BY expiryDate";
      print(query);
      PersistenceManager pm = PMF.get().getPersistenceManager();
      Query q = pm.newQuery(query);
      Queue queue = QueueFactory.getDefaultQueue();
      @SuppressWarnings("unchecked")
      List<Contract> results = (List<Contract>) q.execute();
      print("Putting in queue for processing " + results.size() + " contracts.");
      for (Contract c : results) {
View Full Code Here

Examples of javax.jdo.PersistenceManager.newQuery()

      long now = (new Date()).getTime();
      query = "SELECT FROM " + Contract.class.getName() + " WHERE laststoredCSV<" + (now - Contract.time_threshold())
          + " && expiryDate==0 && archived==false  ORDER BY laststoredCSV";
      print(query);
      pm = PMF.get().getPersistenceManager();
      q = pm.newQuery(query);

      @SuppressWarnings("unchecked")
      List<Contract> results_remaining = (List<Contract>) q.execute();

      print("Putting in queue for processing " + results_remaining.size() + " contracts.");
View Full Code Here

Examples of javax.jdo.PersistenceManager.newQuery()

  @SuppressWarnings("unchecked")
  public static Config getConfig() throws IOException {
    PersistenceManager pm = PMF.get().getPersistenceManager();
    try {
      String query = "select from " + Config.class.getName();
      List<Config> configs = (List<Config>) pm.newQuery(query).execute();
      if (configs.size() > 0) {
        Config config = configs.get(0);
        return pm.detachCopy(config);
      }
    } catch (Exception e) {
View Full Code Here

Examples of javax.jdo.PersistenceManager.newQuery()

    DataManager dm = DataManagerFactory.getInstance();
    PersistenceManager pm = dm.newPersistenceManager();

    // fetch user
    Query qUser = pm.newQuery(talkfeed.data.User.class);
    qUser.setFilter("id == param");
    qUser.declareParameters("String param");
    qUser.setUnique(true);
    qUser.setRange(0, 1);
    talkfeed.data.User talkfeedUser = (talkfeed.data.User) qUser
View Full Code Here

Examples of javax.jdo.PersistenceManager.newQuery()

    if (talkfeedUser != null) {
      // key from user
      Key key = talkfeedUser.getKey();

      // list subscription
      Query qSub = pm.newQuery(Subscription.class);
      qSub.setFilter("userKey == bk");
      qSub.declareParameters("com.google.appengine.api.datastore.Key bk");

      @SuppressWarnings("unchecked")
      List<Subscription> subs = (List<Subscription>) qSub.execute(key);
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.