I'm having a problem writing a query to get a list of objects by filtering for a another entities key.
Object A has many object Bs. Object A @PersistenceCapable(identityType=IdentityType.APPLICATION, detachable = "true") public class A { @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private Key key; @Persistent(mappedBy = "A") private List<Key> Bs; Object B @PersistenceCapable(identityType=IdentityType.APPLICATION, detachable = "true") public class B { @PrimaryKey @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY) private Key key; @Persistent private Key A; I know the id key for object A and I want to query object B and return all Bs that have object A. I have tried... 1) List<Key> B = A.getBs(); but this has returned me null 2) String query = "select from " + B.class.getName() + " WHERE A == " + A.getKey().getId() + " order by creationDate asc"; but this returns no results I know i have valid data in the datastore since i am viewing A's data and i know that A's key is 5, yet no matter how i query for it.. i get no results. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-java@googlegroups.com To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en -~----------~----~----~----~------~----~------~--~---