barB = BarB.get_by_key_name(keyname)
result = FooA.all().ancestor(barB).filter('myID <', 0)
When I test it on the devappserver v1.1.3 it works correct, and an
entry in index.yaml is made
=======================
- kind: FooA
ancestor: yes
properties:
- name: myID
=======================
When I upload the new code and try it out I get the following error:
=======================
NeedIndexError: no matching index found.
This query needs this index:
- kind: FooA
ancestor: yes
properties:
- name: myID
=======================
When I look in the Dashboard this index is "Serving". And it tells the
index is Ascending sorted, this is maybe the default.
What is the cause of this error?
Djidjadji
Yes Alexander is correct.
I have read the issue and have exact the same problem.
In my index.yaml file there is also the following entry as the first
index, placed by devappserver.py.
=======================
- kind: FooA
ancestor: yes
=======================
This is because in some cases I want all the FooA objects that have a
certain parent.
But sometimes I just need a selection of them, and what I heard from a
Google IO talk was
"If you can: let the Datastore work for you" that is why I added the
filter() call.
But to work around the bug I have done the work myself and implemented
the filter
with python if-statement. At the moment the parent does not have a lot
of FooA childs but that might not be the case in the future ( and then
I get hit by the CPU quota ;-)
djidjadji
2008/9/22 Marzia Niccolai <ma...@google.com>: