Why does this instruction not work?
Hi I'm trying to count using keys only and get an error message when using this line
self.response.out.write(A.all(keys_only=True).count(100000000))
The error message I get is
TypeError: all() got an unexpected keyword argument 'keys_only'
Isn't it supposed to work this way? What am I doing wrong? Thanks `
UPDATE: I 开发者_开发百科found this way worked:
query = A.all()
query._keys_only = True
self.response.out.write(query.count(100000000))
There is problem with SearchableModel and keys_only. you can do some think like this.
query = A.all()
query._keys_only = True
精彩评论