title: object mapping [locations] can't be changed from nested to non-nested
body: <h2> Step1:</h2>
  
  <p>PUT <a href="http://localhost:9200/hindex" rel="nofollow">http://localhost:9200/hindex</a> </p>
  
  <pre><code>  {
        "mappings" : {
              "hProvider":{
                  "properties": {
                      "iPid"  : { 
                          "type": "string"
                      },
                      "pType" : {
                          "type" : "string"
                      },
                      "pInfo" : {
                          "properties":{
                              "businessName": {
                                  "type": "string"
                              },
                              "dob": {
                                  "type": "string"
                              },
                              "firstName": {
                                  "type": "string"
                              },
                              "gender": {
                                  "type": "string",
                                  "index": "not_analyzed"
                              }
                          }
                      },
                      "locations" : {
                          "type" : "nested",
                          "properties" :  {
                              "addressInfo" : {
                                 "properties" : {
                                          "city": {
                                                "type": "string",
                                                "index": "not_analyzed"
                                          },
                                          "county": {
                                                "type": "string",
                                                "index": "not_analyzed"
                                          }
                                  }
                              }
                          }
                      }
                  }
              }
          }
      }
  </code></pre>
  
  <p>GET <a href="http://localhost:9200/hindex/_mapping" rel="nofollow">http://localhost:9200/hindex/_mapping</a></p>
  
  <pre><code>{"hindex":{"mappings":{"hProvider":{"properties":{"iPid":{"type":"string"},"locations":{"type":"nested","properties":{"addressInfo":{"properties":{"city":{"type":"string","index":"not_analyzed"},"county":{"type":"string","index":"not_analyzed"}}}}},"pInfo":{"properties":{"businessName":{"type":"string"},"dob":{"type":"string"},"firstName":{"type":"string"},"gender":{"type":"string","index":"not_analyzed"}}},"pType":{"type":"string"}}}}}}
  </code></pre>
  
  <ol start="3">
  <li>Inserting data </li>
  </ol>
  
  <p>POST <a href="http://localhost:9200/hindex/prof/1/?_create" rel="nofollow">http://localhost:9200/hindex/prof/1/?_create</a></p>
  
  <pre><code>{
                 "iPid"  :  "xyz",
                 "pType" : "HealthCareProfessional",
                 "pInfo": {
                    "businessName" : "hdata",
                    "firstName" : "Dawoods",           
                    "dob" : "11/18/1975",
                    "gender" : "male"
                  },
                  "locations" : [
                      {
                          "addressInfo" : {  "city" : "Olney",  "county" : "UnitedStates" } 
                      }, 
                      {
                          "addressInfo" :  {  "city" : "Rivers", "county" : "United States" }
                      }
                  ]
  }
  </code></pre>
  
  <p>Response :</p>
  
  <pre><code>{"error":{"root_cause":[{"type":"remote_transport_exception","reason":"[node-1][10.194.153.161:9300][indices:data/write/index[p]]"}],"type":"illegal_argument_exception","reason":"object mapping [locations] can't be changed from nested to non-nested"},"status":400}
  </code></pre>
  
  <p>Have tried with different data-sets but no luck, what could be the error on the data ?</p>