# Newbie indexing question

**URL:** <https://discuss.elastic.co/t/newbie-indexing-question/21156>\
**Category:** Elasticsearch\
**Created:** [December 8, 2014, 10:54pm UTC](https://discuss.elastic.co/t/newbie-indexing-question/21156 "2014-12-08T22:54:03Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jeff\_Mixter](https://avatars.discourse-cdn.com/v4/letter/j/f08c70/32.png) [@Jeff\_Mixter](https://discuss.elastic.co/u/Jeff_Mixter)\
**Post date:** [December 8, 2014, 10:54pm UTC](https://discuss.elastic.co/t/newbie-indexing-question/21156/1 "2014-12-08T22:54:03Z")

</div>

Sorry for the rather novice question. I am trying to index a large set of  
data in which I have a field that is sometimes nested and other times not.  
I have tried a variety of things with the mapping file but for some reason,  
I always get an error when elasticsearch tries to index one of the  
documents that has a nest field. Here is the error:

{  
"create": {  
"\_index": "entities",  
"\_type": "concept",  
"\_id":  
"[http://experiment.worldcat.org/entity/work/data/118014578#Topic/frisyrer\_1800\_talet](http://experiment.worldcat.org/entity/work/data/118014578#Topic/frisyrer_1800_talet)",  
"status": 400,  
"error": "MapperParsingException[failed to parse [schema:name]];  
nested: ElasticsearchIllegalArgumentException[unknown property  
[@language]]; "  
}  
}

Here are two example documents:

_Doc 1_

{  
"@context": {  
"bgn": "[http://bibliograph.net/](http://bibliograph.net/)",  
"dc": "[http://purl.org/dc/elements/1.1/](http://purl.org/dc/elements/1.1/)",  
"library": "[http://purl.org/library](http://purl.org/library)",  
"rdfs": "[http://www.w3.org/2000/01/rdf-schema#](http://www.w3.org/2000/01/rdf-schema#)",  
"schema": "[http://schema.org/](http://schema.org/)"  
},  
"@id":  
"[http://experiment.worldcat.org/entity/work/data/118014578#Topic/frisyrer\_1800\_talet](http://experiment.worldcat.org/entity/work/data/118014578#Topic/frisyrer_1800_talet)",  
"schema:name": {  
"@language": "sv",  
"@value": "Frisyrer--1800-talet"  
}  
}

\*_Notice the @language and @value nested fields._

_DOC 2_

{  
"@context": {  
"bgn": "[http://bibliograph.net/](http://bibliograph.net/)",  
"dc": "[http://purl.org/dc/elements/1.1/](http://purl.org/dc/elements/1.1/)",  
"library": "[http://purl.org/library](http://purl.org/library)",  
"rdfs": "[http://www.w3.org/2000/01/rdf-schema#](http://www.w3.org/2000/01/rdf-schema#)",  
"schema": "[http://schema.org/](http://schema.org/)"  
},  
"@id": "[http://id.worldcat.org/fast/1205075](http://id.worldcat.org/fast/1205075)",  
"schema:name": "Ohio"  
}

\*_Notice the schema:name field is just a string_

I am trying to index JSON-LD, so if there are any recommendations on better  
ways to do so, that would be great also.

Thanks,

Jeff Mixter

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/d00e22a6-5cf3-453c-83fb-78f60312bb92%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/d00e22a6-5cf3-453c-83fb-78f60312bb92%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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:** [July 6, 2017, 12:44am UTC](https://discuss.elastic.co/t/newbie-indexing-question/21156/2 "2017-07-06T00:44:50Z")

</div>


