//last process date
Calendar cal2 = Calendar.getInstance();
cal2.add(Calendar.HOUR, -24);
Date lastProcess = cal2.getTime();
DataManager dm = DataManagerFactory.getInstance();
PersistenceManager pm = dm.newPersistenceManager();
User user = dm.getUserFromId(pm , jid);
Query q = pm.newQuery(Subscription.class);
q.setFilter("userKey == uk");
q.declareParameters("com.google.appengine.api.datastore.Key uk");