Hi, I'm afraid that I do not understand your problem. You will need to explain your problem clearly before anyone can help you properly.
On Apr 12, 4:51 am, leongpow <[email protected]> wrote: > Hi all, > > Environment: Netbean (Java) > > after look through few related > post.http://groups.google.com/group/google-appengine/browse_thread/thread/... > > http://groups.google.com/group/google-appengine/browse_thread/thread/... > > http://groups.google.com/group/google-appengine/browse_thread/thread/... > > http://groups.google.com/group/google-appengine/browse_thread/thread/... > > http://groups.google.com/group/google-appengine/browse_thread/thread/... > > http://groups.google.com/group/google-appengine/browse_thread/thread/... > > http://groups.google.com/group/google-appengine/browse_thread/thread/... > > http://googcloudlabs.appspot.com/codelabexercise6.html > > i still cannot solve my problem. > > what i need to achieve is > query the database, to avoid duplicate record to store inside it. > > Some of my records have null value, so when i create a query to do > checking. it creates problem. > > there are 2 ways to retrieve record. > 1. GQL > 2. Filter > > i'd try both but none of it give me correct result (either 0 or all > record returned) > > ******************************************************************************************************************************************** > > Query query = pm.newQuery(beanProperty.class, "source == > 'IProperty' && contactName == 'Kian Law' && propertyEstate == null"); > List<beanProperty> listResult = (List)query.execute(); > > ******************************************************************************************************************************************** > > Query query = pm.newQuery(beanProperty.class); > query.setFilter("source == paramSource && contactName == > paramContactName && propertyEstate ==" + null); > query.declareParameters("String paramSource"); > query.declareParameters("String paramContactName"); > query.declareParameters("String paramPropertyEstate"); > > Map args = new HashMap(); > args.put("paramSource", "IProperty"); > args.put("paramContactName", "Kian Law"); > args.put("paramPropertyEstate", null); > List<beanProperty> listResult = > (List)query.executeWithMap(args); > > ******************************************************************************************************************************************** -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
