Hi Robert,

I can't use the key_name.  The ids are not from my site
i.e.
Lets say the ids are from twitter. I want to know how many of the
twitter users
are registered on my site.   So the ids can exists in the datastore,
but it doesn't have to.

Is the best way to get all the users and filter them manually similar
to what Niklas wrote?

Thanks
John

On Sep 6, 8:22 am, Robert Kluin <robert.kl...@gmail.com> wrote:
> It will not be possible to use IN for something like that.  IN will
> execute a series of queries, and it is is capped at 30.
>
> If possible, I would suggest you make the entity key_name the user's
> id.  Then you can just build a list of keys and fetch those -- but I
> really doubt you'll get anything close to 10K on a single fetch.
>
> Robert
>
>
>
> On Mon, Sep 6, 2010 at 04:51, johnterran <johnter...@gmail.com> wrote:
> > Hi
>
> > In BigTable, what is the most efficient way to do a large IN query?
> > My IN parameter list is typically 500 but can be 10k+
> > i.e.
> > class User(db.Model):
> >    name = db.StringProperty(required = True)
> >    id = db.StringProperty(required = True)
>
> > given a list of ids that can consist of 10k list, i need to retrieve
> > all the names
> >  users = db.GqlQuery("SELECT * FROM User where id IN :1",
> >                            ids)
>
> > what is the best way to do this?
>
> > Thanks
> > John
>
> > --
> > You received this message because you are subscribed to the Google Groups 
> > "Google App Engine" group.
> > To post to this group, send email to google-appeng...@googlegroups.com.
> > To unsubscribe from this group, send email to 
> > google-appengine+unsubscr...@googlegroups.com.
> > 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 google-appeng...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en.

Reply via email to