# Can't add properties to a new type

**URL:** <https://discuss.elastic.co/t/cant-add-properties-to-a-new-type/119637>\
**Category:** Elasticsearch\
**Created:** [February 13, 2018, 12:45pm UTC](https://discuss.elastic.co/t/cant-add-properties-to-a-new-type/119637 "2018-02-13T12:45:04Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![alqamasudofy](https://avatars.discourse-cdn.com/v4/letter/a/c67d28/32.png) [@alqamasudofy](https://discuss.elastic.co/u/alqamasudofy)\
**Post date:** [February 13, 2018, 12:45pm UTC](https://discuss.elastic.co/t/cant-add-properties-to-a-new-type/119637/1 "2018-02-13T12:45:04Z")

</div>

```auto
    PUT /customers/_mapping/instore
{
  "properties":{
    "name":{
      "type":"text",
      "analyzer":"standard"
    }
  }
}

```

ERROR:

```auto
{
  "error": {
    "root_cause": [
      {
        "type": "illegal_argument_exception",
        "reason": "Rejecting mapping update to [customers] as the final mapping would have more than 1 type: [instore, online]"
      }
    ],
    "type": "illegal_argument_exception",
    "reason": "Rejecting mapping update to [customers] as the final mapping would have more than 1 type: [instore, online]"
  },
  "status": 400
}

```

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [February 13, 2018, 12:58pm UTC](https://discuss.elastic.co/t/cant-add-properties-to-a-new-type/119637/2 "2018-02-13T12:58:23Z")

</div>

You can't add 2 types in a 6.x index.

---

<div class="post-metadata">

**Author:** ![alqamasudofy](https://avatars.discourse-cdn.com/v4/letter/a/c67d28/32.png) [@alqamasudofy](https://discuss.elastic.co/u/alqamasudofy)\
**Post date:** [February 13, 2018, 1:07pm UTC](https://discuss.elastic.co/t/cant-add-properties-to-a-new-type/119637/3 "2018-02-13T13:07:21Z")

</div>

Can you please elaborate?  
What if I want to use two types `online` and `instore` and I want to set the properties for both of them?

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [February 13, 2018, 1:17pm UTC](https://discuss.elastic.co/t/cant-add-properties-to-a-new-type/119637/4 "2018-02-13T13:17:12Z")

</div>

Read [this blog post about the removal of types in Elasticsearch 6.0](https://www.elastic.co/blog/removal-of-mapping-types-elasticsearch).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [March 13, 2018, 1:17pm UTC](https://discuss.elastic.co/t/cant-add-properties-to-a-new-type/119637/5 "2018-03-13T13:17:25Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
