|
mongo数组如下:
PHP复制代码
array (
'_id' => new MongoId ("5281d8fa942a88200e000000"),
'uid' => new MongoInt32 (3000001),
'cardsBag' =>
array (
'0' =>
array (
'id' => new MongoInt32 (3),
'count' => new MongoInt32 (1),
'fightIndex' => new MongoInt32 (6),
'property' =>
array (
'0' => new MongoInt32 (99),
'1' => new MongoInt32 (321),
),
),
'1' =>
array (
'id' => new MongoInt32 (110),
'count' => new MongoInt32 (1),
'fightIndex' => new MongoInt32 (1),
'property' =>
array (
'0' => new MongoInt32 (99),
'1' => new MongoInt32 (123),
),
),
'2' =>
array (
'id' => new MongoInt32 (98),
'count' => new MongoInt32 (1),
'fightIndex' => new MongoInt32 (-1),
'property' =>
array (
'0' => new MongoInt32 (99),
'1' => new MongoInt32 (234),
),
),
'3' =>
array (
'id' => new MongoInt32 (96),
'count' => new MongoInt32 (1),
'fightIndex' => new MongoInt32 (0),
'property' =>
array (
'0' => new MongoInt32 (99),
'1' => new MongoInt32 (432),
),
),
),) 复制代码
我想更改这个数组里的cardsBag里的第二个数组里面的值。update 要怎么写呢?
|
|