Just have a parent referenceproperty in the child and then use the backref collection
In your case that will be the most efficient I think. T On Sep 21, 5:21 pm, Martin Webb <[email protected]> wrote: > Hi Tim. Just saw your last post. No i dont need something that complex. I dont > need to sort them tho they could run into many thousands and beyond. I only > need > to load a say 10-100 at a time for display purposes. I did consider > implementing > as you have shown using the list property. But the issue of max 5000 entries > plus the concurrency if multiple threads write made use a far less extragant > model of just storing a domain key and then a key to a child as ref. i can > then > just fetch the childs by domain and then load them by key. It seems to work > fine. Still pondering if it would be best to use a list property as you say > ;-) > > Regards > > Martin Webb > > T. 01233 660879 > F. 01233 640949 > M. 07798946071 > > The information contained in this email is confidential and may contain > proprietary information. It is meant solely for the intended recipient. Access > to this email by anyone else is unauthorised. If you are not the intended > recipient, any disclosure, copying, distribution or any action taken or > omitted > in reliance on this, is prohibited and may be unlawful. No liability or > responsibility is accepted if information or data is, for whatever reason > corrupted or does not reach its intended recipient. No warranty is given that > this email is free of viruses. The views expressed in this email are, unless > otherwise stated, those of the author > > ________________________________ > From: Tim Hoffman <[email protected]> > To: Google App Engine <[email protected]> > Sent: Tue, 21 September, 2010 10:14:02 > Subject: [google-appengine] Re: parent relationships > > If you want to entity groups and ancestor queries, I would define a > property of the children identifying depth from root. > The you can do a kindless ancestor query and filter by depth of parent > + 1 > > T > > On Sep 21, 4:52 pm, Martin Webb <[email protected]> wrote: > > > > > > > > > > > @tim > > > If i do need to store children with in children - and if i have childs that > > could run to say one level but perhaps 500-1000 entities is it best to use a > > different aproach? > > Thinking about this i do need to store children with-in children so it > > sounds > > like i would have a problem getting the right level etc. > > Am i correct. > > > Regards > > > Martin Webb > > The information contained in this email is confidential and may contain > > proprietary information. It is meant solely for the intended recipient. > > Access > > to this email by anyone else is unauthorised. If you are not the intended > > recipient, any disclosure, copying, distribution or any action taken or > omitted > > in reliance on this, is prohibited and may be unlawful. No liability or > > responsibility is accepted if information or data is, for whatever reason > > corrupted or does not reach its intended recipient. No warranty is given > > that > > this email is free of viruses. The views expressed in this email are, unless > > otherwise stated, those of the author > > > ________________________________ > > From: Tim Hoffman <[email protected]> > > To: Google App Engine <[email protected]> > > Sent: Tue, 21 September, 2010 9:34:23 > > Subject: [google-appengine] Re: parent relationships > > > Hi > > > On Sep 21, 3:52 pm, Martin Webb <[email protected]> wrote:> Hi is it > >possible to add a entity of a model with a parent set to a key or > > > another entity of the same model class. > > > Parents can be any entity class. > > > > If so; does this make finding the > > > siblings easier? If i load the parent or the sibling (child) is it easier > > > to > > > find the relating party(s). > > > Yes, if you only have one level of children below the parent. Children > > within in children will mean you will get all children when doing a > > straight ancestor query. > > > Remember you are also creating an entity group. So make sure you > > don't create huge tree with a single parent ;-) > > > T > > > > Regards > > > > Martin Webb > > > > The information contained in this email is confidential and may contain > > > proprietary information. It is meant solely for the intended recipient. > >Access > > > to this email by anyone else is unauthorised. If you are not the intended > > > recipient, any disclosure, copying, distribution or any action taken or > > omitted > > > in reliance on this, is prohibited and may be unlawful. No liability or > > > responsibility is accepted if information or data is, for whatever reason > > > corrupted or does not reach its intended recipient. No warranty is given > that > > > this email is free of viruses. The views expressed in this email are, > > > unless > > > otherwise stated, those of the author > > > -- > > 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 > >athttp://groups.google.com/group/google-appengine?hl=en. > > -- > 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 > athttp://groups.google.com/group/google-appengine?hl=en. -- 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.
