Object mapping [channels.channel_people] can't be changed from nested to non-nested

I first created a mapping.

PUT /my_index/
{
  "mappings": {
    "properties": {
      "channels": {
        "type": "object",
        "properties": {
          "channel_people": {
            "type": "nested",
            "properties": {
              "email": {
                "type": "text",
                "fields": {
                  "keyword": {
                    "type": "keyword",
                    "ignore_above": 256
                  }
                }
              },
              "id": {
                "type": "text",
                "fields": {
                  "keyword": {
                    "type": "keyword",
                    "ignore_above": 256
                  }
                }
              }
            }
          },
          "subtype": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          },
          "channel_type": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          },
          "source_type": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      }
    }
  }
}



POST my_index/my_type/12
{
  "channels": [
    {
      "channel_label": "some_value",
      "channel_subtype": "some_value",
      "source_type": "some_value",
      "channel_people": [
        {
          "id": "some_value",
          "email": "some_value"
        },
        {
          "id": "some_value",
          "email": "some_value"
        }
      ],
      "channel_type": "some_value",
      "channel_id": "some_value"
    }
  ]
}

After executing POST request, I get object mapping [channels.channel_people] can't be changed from nested to non-nested

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