Create a parent-child relationship after the parent type already exists
<p>I'm trying to add a new type as a child of an existing type. From <a href="https://www.elastic.co/guide/en/elasticsearch/guide/current/parent-child-mapping.html" rel="nofollow">ElasticSearch documentation</a>, it looks like this is possible but there is no details about how to do it. </p>

<p>Here's what the documentation says:</p>

<blockquote>
  <p>This must be done at index creation time, or with the update-mapping API before the child type has been created.</p>
</blockquote>

<p>There are no details about setting up a parent-child relationship in the <a href="https://www.elastic.co/guide/en/elasticsearch/reference/2.x/indices-put-mapping.html" rel="nofollow">update-mapping API documentation</a>. </p>

<p>Intuitively, I think a parent-child relationship should be allowed to be established after a parent already exists since the parent does not need to know anything about the child.</p>

<p>Here's the error I'm getting when I create a new type as a child:</p>

<pre><code>{
"error": {
  "root_cause": [
    {
      "type": "illegal_argument_exception",
      "reason": "can't add a _parent field that points to an already existing type"
    }
  ],
  "type": "illegal_argument_exception",
  "reason": "can't add a _parent field that points to an already existing type"
},
"status": 400
}
</code></pre>