# Issue with elasticsearch document mapping and reading the data

**URL:** <https://discuss.elastic.co/t/issue-with-elasticsearch-document-mapping-and-reading-the-data/27425>\
**Category:** Elasticsearch\
**Created:** [August 14, 2015, 7:07pm UTC](https://discuss.elastic.co/t/issue-with-elasticsearch-document-mapping-and-reading-the-data/27425 "2015-08-14T19:07:18Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![adityai](https://avatars.discourse-cdn.com/v4/letter/a/7c8e57/32.png) [@adityai](https://discuss.elastic.co/u/adityai)\
**Post date:** [August 14, 2015, 7:07pm UTC](https://discuss.elastic.co/t/issue-with-elasticsearch-document-mapping-and-reading-the-data/27425/1 "2015-08-14T19:07:18Z")

</div>

I have a customer index that I created by following the getting started guide.

curl -XGET 'localhost:9200/customer/\_mapping?pretty'  
{  
"customer" : {  
"mappings" : {  
"external" : {  
"properties" : {  
"name" : {  
"type" : "string"  
}  
}  
}  
}  
}  
}

I am able to view the information stored in /customer/external/1 as follows:  
curl -XGET 'localhost:9200/customer/external/1?pretty'  
{  
"\_index" : "customer",  
"\_type" : "external",  
"\_id" : "1",  
"\_version" : 1,  
"found" : true,  
"\_source":  
{  
"name": "John Doe"  
}

I have another index named 'logstash'

curl -XGET 'localhost:9200/logstash/\_mapping?pretty'  
{  
"logstash" : {  
"mappings" : {  
"type" : {  
"properties" : {  
"@timestamp" : {  
"type" : "date",  
"format" : "dateOptionalTime"  
},  
"@version" : {  
"type" : "long"  
},  
"data" : {  
"properties" : {  
"buildDuration" : {  
"type" : "long"  
},  
"buildHost" : {  
"type" : "string"  
},  
"buildLabel" : {  
"type" : "string"  
},  
"buildNum" : {  
"type" : "long"  
},  
"buildVariables" : {  
"type" : "object"  
},  
"displayName" : {  
"type" : "string"  
},  
"fullDisplayName" : {  
"type" : "string"  
},  
"id" : {  
"type" : "string"  
},  
"projectName" : {  
"type" : "string"  
},  
"rootBuildNum" : {  
"type" : "long"  
},  
"rootProjectDisplayName" : {  
"type" : "string"  
},  
"rootProjectName" : {  
"type" : "string"  
},  
"timestamp" : {  
"type" : "date",  
"format" : "dateOptionalTime"  
},  
"url" : {  
"type" : "string"  
}  
}  
},  
"message" : {  
"type" : "string"  
},  
"source" : {  
"type" : "string"  
},  
"source\_host" : {  
"type" : "string"  
}  
}  
}  
}  
}  
}

I cannot figure out how to display the information that is stored in this logstash index. I can see that there are 36 items in the index, but I cannot figure out how to display even one of them.

curl -XGET '[http://localhost:9200/\_cat/indices/logstash?v](http://localhost:9200/_cat/indices/logstash?v)'  
health status index pri rep docs.count docs.deleted store.size pri.store.size  
yellow open logstash 5 1 36 0 162.6kb 162.6kb

I have been following the getting started guide, but the customer example they have seems simpler than the one I have in my logstash index. Please help me figure out how to display this information.

---

<div class="post-metadata">

**Author:** ![mosiddi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mosiddi/32/577_2.png) [@mosiddi](https://discuss.elastic.co/u/mosiddi)\
**Post date:** [August 15, 2015, 6:01am UTC](https://discuss.elastic.co/t/issue-with-elasticsearch-document-mapping-and-reading-the-data/27425/2 "2015-08-15T06:01:09Z")

</div>

If you have \_source ON, you can do a match\_all [[https://www.elastic.co/guide/en/elasticsearch/reference/1.6/query-dsl-match-all-query.html](https://www.elastic.co/guide/en/elasticsearch/reference/1.6/query-dsl-match-all-query.html)] search, specify fields you are interested to get back and display the information.

---

<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 5, 2017, 11:55pm UTC](https://discuss.elastic.co/t/issue-with-elasticsearch-document-mapping-and-reading-the-data/27425/3 "2017-07-05T23:55:41Z")

</div>


