# Beginner question

**URL:** <https://discuss.elastic.co/t/beginner-question/17215>\
**Category:** Elasticsearch\
**Created:** [April 26, 2014, 3:53pm UTC](https://discuss.elastic.co/t/beginner-question/17215 "2014-04-26T15:53:12Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jinyuan\_Zhou](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jinyuan_zhou/32/90185_2.png) [@Jinyuan\_Zhou](https://discuss.elastic.co/u/Jinyuan_Zhou)\
**Post date:** [April 26, 2014, 3:53pm UTC](https://discuss.elastic.co/t/beginner-question/17215/1 "2014-04-26T15:53:12Z")

</div>

I am following the definitive guide. I added this docume by issue this in  
sense  
PUT /megacorp/employee/1  
{  
"first\_name" : "John",  
"last\_name" : "Smith",  
"age" : 25,  
"about" : "I love to go rock climbing",  
"interests": ["sports", "music"]  
}

when I try to retrieve the docoment  
by doing this

GET /megacorp/employee/1

But I didn't get original json back. It get some description of the stored  
document like this.  
{  
"\_index": "megacorp",  
"\_type": "employee",  
"\_id": "1",  
"\_version": 2,  
"found": true  
}.

I did this on command line using cur. Same result come back.

What do I missing? Thanks,

--  
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/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![vineeth\_mohan\_2](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vineeth_mohan_2/32/747_2.png) [@vineeth\_mohan\_2](https://discuss.elastic.co/u/vineeth_mohan_2)\
**Post date:** [April 26, 2014, 4:00pm UTC](https://discuss.elastic.co/t/beginner-question/17215/2 "2014-04-26T16:00:57Z")

</div>

Hi ,

Can you try the insert using POST and paste the result.

Thanks  
Vineeth

On Sat, Apr 26, 2014 at 9:23 PM, Jinyuan Zhou [zhou.jinyuan@gmail.com](mailto:zhou.jinyuan@gmail.com)wrote:

> I am following the definitive guide. I added this docume by issue this in  
> sense  
> PUT /megacorp/employee/1  
> {  
> "first\_name" : "John",  
> "last\_name" : "Smith",  
> "age" : 25,  
> "about" : "I love to go rock climbing",  
> "interests": ["sports", "music"]  
> }
> 
> when I try to retrieve the docoment  
> by doing this
> 
> GET /megacorp/employee/1
> 
> But I didn't get original json back. It get some description of the stored  
> document like this.  
> {  
> "\_index": "megacorp",  
> "\_type": "employee",  
> "\_id": "1",  
> "\_version": 2,  
> "found": true  
> }.
> 
> I did this on command line using cur. Same result come back.
> 
> What do I missing? Thanks,
> 
> --  
> 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/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com)[https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com?utm_medium=email&utm_source=footer)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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/CAGdPd5%3DASvTuLvDb\_ixQOW1krSw70dtX0CpiMXkfLNGrxmY0HQ%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAGdPd5%3DASvTuLvDb_ixQOW1krSw70dtX0CpiMXkfLNGrxmY0HQ%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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:** [April 26, 2014, 4:11pm UTC](https://discuss.elastic.co/t/beginner-question/17215/3 "2014-04-26T16:11:48Z")

</div>

Can you get your mapping?  
May be you disabled \_source field?

--  
David 😉  
Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs

> Le 26 avr. 2014 à 17:53, Jinyuan Zhou [zhou.jinyuan@gmail.com](mailto:zhou.jinyuan@gmail.com) a écrit :
> 
> I am following the definitive guide. I added this docume by issue this in sense  
> PUT /megacorp/employee/1  
> {  
> "first\_name" : "John",  
> "last\_name" : "Smith",  
> "age" : 25,  
> "about" : "I love to go rock climbing",  
> "interests": ["sports", "music"]  
> }
> 
> when I try to retrieve the docoment  
> by doing this
> 
> GET /megacorp/employee/1
> 
> But I didn't get original json back. It get some description of the stored document like this.  
> {  
> "\_index": "megacorp",  
> "\_type": "employee",  
> "\_id": "1",  
> "\_version": 2,  
> "found": true  
> }.
> 
> I did this on command line using cur. Same result come back.
> 
> ## What do I missing? Thanks,
> 
> 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/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com).  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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/13E73F62-48DD-446A-83C2-3AAE696325E7%40pilato.fr](https://groups.google.com/d/msgid/elasticsearch/13E73F62-48DD-446A-83C2-3AAE696325E7%40pilato.fr).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Rafal\_Kuc\_3](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rafal_kuc_3/32/799_2.png) [@Rafal\_Kuc\_3](https://discuss.elastic.co/u/Rafal_Kuc_3)\
**Post date:** [April 26, 2014, 4:14pm UTC](https://discuss.elastic.co/t/beginner-question/17215/4 "2014-04-26T16:14:06Z")

</div>

Hello!

You should have your results returned unless you disabled \_source field in the mappings. Can you show us result of:

curl -XGET 'localhost:9200/megacorp/employee/\_mapping?pretty'

_--_

Regards,

Rafał Kuć

Performance Monitoring \* Log Analytics \* Search Analytics

Solr & Elasticsearch Support \* [http://sematext.com/](http://sematext.com/)

Hi ,

Can you try the insert using POST and paste the result.

Thanks

```
       Vineeth

```

On Sat, Apr 26, 2014 at 9:23 PM, Jinyuan Zhou \<[zhou.jinyuan@gmail.com](mailto:zhou.jinyuan@gmail.com)\> wrote:

I am following the definitive guide. I added this docume by issue this in sense

PUT /megacorp/employee/1

{

```
"first_name" : "John",

"last_name" : "Smith",

"age" : 25,

"about" : "I love to go rock climbing",

"interests": ["sports", "music"]

```

}

when I try to retrieve the docoment

by doing this

GET /megacorp/employee/1

But I didn't get original json back. It get some description of the stored document like this.

{

"\_index": "megacorp",

"\_type": "employee",

"\_id": "1",

"\_version": 2,

"found": true

}.

I did this on command line using cur. Same result come back.

What do I missing? Thanks,

--

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/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com?utm_medium=email&utm_source=footer).

For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--

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/CAGdPd5%3DASvTuLvDb\_ixQOW1krSw70dtX0CpiMXkfLNGrxmY0HQ%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAGdPd5%3DASvTuLvDb_ixQOW1krSw70dtX0CpiMXkfLNGrxmY0HQ%40mail.gmail.com?utm_medium=email&utm_source=footer).

For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Jinyuan\_Zhou](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jinyuan_zhou/32/90185_2.png) [@Jinyuan\_Zhou](https://discuss.elastic.co/u/Jinyuan_Zhou)\
**Post date:** [April 26, 2014, 4:19pm UTC](https://discuss.elastic.co/t/beginner-question/17215/5 "2014-04-26T16:19:58Z")

</div>

Thanks yes, I am not running on a clean installation. Yes the \_source is  
disabled.

{  
"megacorp" : {  
"mappings" : {  
"employee" : {  
"\_source" : {  
"enabled" : false  
},  
"properties" : {  
"about" : {  
"type" : "string"  
},  
"age" : {  
"type" : "long"  
},  
"first\_name" : {  
"type" : "string"  
},  
"interests" : {  
"type" : "string"  
},  
"last\_name" : {  
"type" : "string"  
}  
}  
}  
}  
}  
}

On Saturday, April 26, 2014 9:14:06 AM UTC-7, Rafał Kuć wrote:

> Hello!
> 
> You should have your results returned unless you disabled \_source field in  
> the mappings. Can you show us result of:
> 
> curl -XGET 'localhost:9200/megacorp/employee/\_mapping?pretty'
> 
> \*-- Regards, Rafał Kuć Performance Monitoring \* Log Analytics \* Search  
> Analytics Solr & Elasticsearch Support \* \*[http://sematext.com/](http://sematext.com/)
> 
> Hi ,
> 
> Can you try the insert using POST and paste the result.
> 
> Thanks  
> Vineeth
> 
> On Sat, Apr 26, 2014 at 9:23 PM, Jinyuan Zhou \<[zhou.j...@gmail.com](mailto:zhou.j...@gmail.com)\<javascript:\>\>  
> wrote:  
> I am following the definitive guide. I added this docume by issue this in  
> sense  
> PUT /megacorp/employee/1  
> {  
> "first\_name" : "John",  
> "last\_name" : "Smith",  
> "age" : 25,  
> "about" : "I love to go rock climbing",  
> "interests": ["sports", "music"]  
> }
> 
> when I try to retrieve the docoment  
> by doing this
> 
> GET /megacorp/employee/1
> 
> But I didn't get original json back. It get some description of the stored  
> document like this.  
> {  
> "\_index": "megacorp",  
> "\_type": "employee",  
> "\_id": "1",  
> "\_version": 2,  
> "found": true  
> }.
> 
> I did this on command line using cur. Same result come back.
> 
> ## What do I missing? Thanks,
> 
> ## 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 [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com) \<javascript:\>. To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com)[https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com?utm_medium=email&utm_source=footer) . For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> 
> 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 [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com) \<javascript:\>.  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CAGdPd5%3DASvTuLvDb\_ixQOW1krSw70dtX0CpiMXkfLNGrxmY0HQ%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAGdPd5%3DASvTuLvDb_ixQOW1krSw70dtX0CpiMXkfLNGrxmY0HQ%40mail.gmail.com)[https://groups.google.com/d/msgid/elasticsearch/CAGdPd5%3DASvTuLvDb\_ixQOW1krSw70dtX0CpiMXkfLNGrxmY0HQ%40mail.gmail.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/CAGdPd5%3DASvTuLvDb_ixQOW1krSw70dtX0CpiMXkfLNGrxmY0HQ%40mail.gmail.com?utm_medium=email&utm_source=footer)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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/d522e62b-a7d0-455f-ac19-8a88f2acd22e%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/d522e62b-a7d0-455f-ac19-8a88f2acd22e%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Jinyuan\_Zhou](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jinyuan_zhou/32/90185_2.png) [@Jinyuan\_Zhou](https://discuss.elastic.co/u/Jinyuan_Zhou)\
**Post date:** [April 26, 2014, 4:29pm UTC](https://discuss.elastic.co/t/beginner-question/17215/6 "2014-04-26T16:29:52Z")

</div>

Thanks David, Yet it is mapping. I started from a clean installation. the  
json does comeback

On Saturday, April 26, 2014 9:11:48 AM UTC-7, David Pilato wrote:

> Can you get your mapping?  
> May be you disabled \_source field?
> 
> --  
> David 😉  
> Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> 
> Le 26 avr. 2014 à 17:53, Jinyuan Zhou \<[zhou.j...@gmail.com](mailto:zhou.j...@gmail.com) \<javascript:\>\>  
> a écrit :
> 
> I am following the definitive guide. I added this docume by issue this in  
> sense  
> PUT /megacorp/employee/1  
> {  
> "first\_name" : "John",  
> "last\_name" : "Smith",  
> "age" : 25,  
> "about" : "I love to go rock climbing",  
> "interests": ["sports", "music"]  
> }
> 
> when I try to retrieve the docoment  
> by doing this
> 
> GET /megacorp/employee/1
> 
> But I didn't get original json back. It get some description of the stored  
> document like this.  
> {  
> "\_index": "megacorp",  
> "\_type": "employee",  
> "\_id": "1",  
> "\_version": 2,  
> "found": true  
> }.
> 
> I did this on command line using cur. Same result come back.
> 
> What do I missing? Thanks,
> 
> --  
> 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 [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com) \<javascript:\>.  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com)[https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/73171fd0-dc65-4c3d-9493-5e6b9f62a6ba%40googlegroups.com?utm_medium=email&utm_source=footer)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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/6f5acc67-8357-4aa4-993a-6bfe1bd1a864%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/6f5acc67-8357-4aa4-993a-6bfe1bd1a864%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, 1:33am UTC](https://discuss.elastic.co/t/beginner-question/17215/7 "2017-07-06T01:33:16Z")

</div>

Closed on July 6, 2017, 1:33am UTC


