[appengine-java] Re: Efficient One to Many Relationship

2010-05-01 Thread Pk
it is the first 100 records order by date descending. On Apr 30, 10:28 am, Tristan tristan.slomin...@gmail.com wrote: what does it mean I'll get only the top 100 at any given time. ? How do you determine top ? On Apr 27, 9:19 pm, Pk prakash...@gmail.com wrote: Btw, I am not going to get

[appengine-java] Re: Efficient One to Many Relationship

2010-05-01 Thread Tristan
you should be fine then... just add sort according to date descending, and set limit to 100. that way the datastore does everything for you. one call, pretty good i think. On May 1, 9:08 am, Pk prakash...@gmail.com wrote: it is the first 100 records order by date descending. On Apr 30, 10:28 

[appengine-java] Re: Efficient One to Many Relationship

2010-04-27 Thread Tristan
1) yes, that should work just fine (at least in low-level datastore API it does) 2) your key should not be your security / accessibility mechanism, so yes, it should be fine (although using a Long id vs. keyAsString would be prettier). also, you want to make sure you restrict access to your

[appengine-java] Re: Efficient One to Many Relationship

2010-04-27 Thread Pk
Thank you so much Tristan. I have another question on top of #3. I can query on listitem parentkey = listcontainerkey and isproccess = true. it is easier, yes. but I expect the data to be growing. there;ll be lot of users with all their listitems stored in a single big list, the processed and

[appengine-java] Re: Efficient One to Many Relationship

2010-04-27 Thread Pk
Btw, I am not going to get all the isprocessed=true records at once. I'll get only the top 100 at any given time. On Apr 28, 7:05 am, Pk prakash...@gmail.com wrote: Thank you so much Tristan. I have another question on top of #3. I can query on listitem parentkey = listcontainerkey and