I'd like to migrate a DB from a replica set to another which belongs to a sharded cluster. Till now, this cluster has got only 1 shard, and no collection or database is really sharded.
I mongodumped and restored this DB. From one of the sharded cluster's mongos, I can run a simple query like find() but something including a projection like the following doesn't work anymore:
"find({"var1":subvar},{"_id":0, "fld1":1, "fld2":1, "fld3":1}).limit(1).sort("_id",pymongo.DESCENDING)"
I get the following error message:
database error: have to have sort key in projection and removing it
It has to be a problem related to the sharding because I restored this DB to a dev standalone mongodb server and the test ran successfully.
Thanks in advance,
Greg.