-
Type: Bug
-
Resolution: Cannot Reproduce
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Write Ops
-
None
-
Environment:win7 x64
Wed Apr 21 22:34:00 Mongo DB : starting : pid = 0 port = 27333 dbpath = d:/mongodb/data master = 0 slave = 0 64-bit
****
WARNING: This is development version of MongoDB. Not recommended for production.
****
Wed Apr 21 22:34:00 db version v1.5.1-pre-, pdfile version 4.5
Wed Apr 21 22:34:00 git version: f528f30c4fb604600f24d227c1c57e5c7bbfd191
Wed Apr 21 22:34:00 sys info: windows (6, 0, 6002, 2, 'Service Pack 2') BOOST_LIB_VERSION=1_39
> db.test.drop()
true
> db.test.insert({a: [
,
{id: 2, x: [8,9,10]}]})
> db.test.update(
, {$set: {'a.$.x': [1,1,1]}})
> db.test.find()
{ "_id" : ObjectId("4bcfc3e47c39000000001d80"), "a" : [
,
{ "id" : 2, "x" : [ 8, 9, 10 ] }] }
> db.test.ensureIndex(
)
> db.test.update(
, {$set: {'a.$.x': [1,2,2]}})
can't append to array using string field name
> db.test.dropIndex(
)
{ "nIndexesWas" : 2, "ok" : 1 }> db.test.update(
{'a.id': 1}, {$set: {'a.$.x': [6,6,7]}})
> db.test.find()
{ "_id" : ObjectId("4bcfc3e47c39000000001d80"), "a" : [
,
{ "id" : 2, "x" : [ 8, 9, 10 ] }] }
>