Strange error: err: API error 4 (datastore_v3: NEED_INDEX): no matching index found.

217 views
Skip to first unread message

Ralf Rottmann

unread,
May 3, 2014, 5:33:07 AM5/3/14
to google-ap...@googlegroups.com
I'm running the following query, where HasProfileImage is a bool property on the entity.

_, err := datastore.NewQuery(config.DatastoreUserProfileKind).Limit(100).Filter("HasProfileImage", true).Order("-Updated").GetAll(c, &us)

I get the err: API error 4 (datastore_v3: NEED_INDEX): no matching index found. error. When I manually add the index to index.yaml, appcfg.py update_indexes . complains, that I don't need to manually add indexes for primary properties and should remove it.

Any idea?


--

Glenn Lewis

unread,
May 3, 2014, 7:50:25 PM5/3/14
to Ralf Rottmann, google-appengine-go

Typically you run the dev appserver and run your new query and then it will automatically update your index.yaml file for you. You then deploy your app again with the new index.yaml file, wait for the new index to be built in production, then start using it.

Is this issue now resolved for you?

--
You received this message because you are subscribed to the Google Groups "google-appengine-go" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-appengin...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages