Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

regression: Multifield mapping failing on 1.0.0RC1 #5016

Closed
nahap opened this issue Feb 5, 2014 · 2 comments
Closed

regression: Multifield mapping failing on 1.0.0RC1 #5016

nahap opened this issue Feb 5, 2014 · 2 comments

Comments

@nahap
Copy link

nahap commented Feb 5, 2014

When creating A Multi_field mapping on 1.0.0.RC1, the mapping returned is "string", instead of "multi_field". When using 0.90.10, the same curl request work correctly, returning "multi_field" as mapping:

curl -XDELETE http://localhost:9200/test_index/product/_mapping
curl -XDELETE http://localhost:9200/test_index

curl -XPUT http://localhost:9200/test_index
curl -XPUT http://localhost:9200/test_index/product/_mapping -d '
{
    "product": {
        "properties": {
            "mf_test" : {
                "type" : "multi_field",
                "fields" : {
                    "name" : {"type" : "string", "index" : "analyzed"},
                    "untouched" : {"type" : "string", "index" : "not_analyzed"}
                }
            }
        }
    }
}'
curl -XGET http://localhost:9200/test_index/product/_mapping

 curl -XPUT 'http://localhost:9200/test_index/product/1' -d '
 {
    "id": 1,
    "mf_test" : "anything"
 }'

curl -XGET http://localhost:9200/test_index/product/_mapping


{
    "test_index": {
        "mappings": {
            "product": {
                "properties": {
                    "mf_test": {
                        "type": "string",
                        "index": "no",
                        "fields": {
                            "name": {
                                "type": "string"
                            },
                            "untouched": {
                                "type": "string",
                                "index": "not_analyzed",
                                "norms": {
                                    "enabled": false
                                },
                                "index_options": "docs"
                            }
                        }
                    }
                }
            }
        }
    }
}

as you see in the result of the get mapping request the type of "mf_test" is "string" instead of multifield.

@dadoonet
Copy link
Member

dadoonet commented Feb 5, 2014

Hi

I think it's documented here: http://www.elasticsearch.org/guide/en/elasticsearch/reference/master/_multi_fields.html

Feel free to reopen if needed.

@dadoonet dadoonet closed this as completed Feb 5, 2014
@nahap
Copy link
Author

nahap commented Feb 5, 2014

Ok, then i had to reread the documentation, Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants