I have a document user that have a schema as:

```
{
    "_id" : ObjectId("57b2d706f61d04e8d99dd983"),
    "addressesAsVendor" : [ 
        {
            "_id" : "V1",
            "addressLine1" : "al1",
            "addressLine2" : "al2",
            "street" : "street",
            "city" : "city",
            "country" : "IN",
            "pincode" : "490020",
            "location" : {
                "latitutde" : "lat1",
                "longitude" : "lon1"
            }
        }, 
        {
            "_id" : "V2",
            "addressLine1" : "al1",
            "addressLine2" : "al2",
            "street" : "street",
            "city" : "city",
            "country" : "IN",
            "pincode" : "490020",
            "location" : {
                "latitutde" : "lat2",
                "longitude" : "lon2"
            }
        }
    ]
}

```

Now let's suppose I want to update the **V1** id of the **addressesAsVendor** array which is inside the user Id **57b2d706f61d04e8d99dd983** with the data:

```
{
    "addressLine1" : "al1 new",
    "addressLine2" : "al2 new",
    "street" : "street new",
    "city" : "city new",
    "country" : "IN new",
    "pincode" : "490020 new",
    "location" : {
       "latitutde" : "lat1 new",
       "longitude" : "lon1 new"
    }
}

```

So the new user doc will look like:

```
{
    "_id" : ObjectId("57b2d706f61d04e8d99dd983"),
    "addressesAsVendor" : [ 
        {
            "_id" : "V1",
            "addressLine1" : "al1 new",
            "addressLine2" : "al2 new",
            "street" : "street new",
            "city" : "city new",
            "country" : "IN new",
            "pincode" : "490020 new",
            "location" : {
              "latitutde" : "lat1 new",
              "longitude" : "lon1 new"
            }
        }, 
        {
            "_id" : "V2",
            "addressLine1" : "al1",
            "addressLine2" : "al2",
            "street" : "street",
            "city" : "city",
            "country" : "IN",
            "pincode" : "490020",
            "location" : {
                "latitutde" : "lat2",
                "longitude" : "lon2"
            }
        }
    ]
}

```

How this can be achieved in **MongoDb** and what's the best way of keeping multiple addresses, which can be easily shown in the Address page of the user and also minimum in load, I mean will be easy to access when required.

Please shed your views.
:)