# Simple term query problem

**URL:** <https://discuss.elastic.co/t/simple-term-query-problem/8865>\
**Category:** Elasticsearch\
**Created:** [August 28, 2012, 1:34am UTC](https://discuss.elastic.co/t/simple-term-query-problem/8865 "2012-08-28T01:34:57Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jack\_Markarian](https://avatars.discourse-cdn.com/v4/letter/j/34f0e0/32.png) [@Jack\_Markarian](https://discuss.elastic.co/u/Jack_Markarian)\
**Post date:** [August 28, 2012, 1:34am UTC](https://discuss.elastic.co/t/simple-term-query-problem/8865/1 "2012-08-28T01:34:57Z")

</div>

I have a very simple test case represented here: [http://pastie.org/4600683](http://pastie.org/4600683)

I am having trouble understanding why the second and third query is not  
returning the document I have indexed the same way the first query returns  
the document. Any assistance would be greatly appreciated!

Note that the first curl statement creates the index (which means I'm using  
the dynamic mapping functionality.. I can't use a static mapping  
file, unfortunately).

--

---

<div class="post-metadata">

**Author:** ![Shaun\_Etherton](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/shaun_etherton/32/2540_2.png) [@Shaun\_Etherton](https://discuss.elastic.co/u/Shaun_Etherton)\
**Post date:** [August 28, 2012, 1:40am UTC](https://discuss.elastic.co/t/simple-term-query-problem/8865/2 "2012-08-28T01:40:27Z")

</div>

Hi,  
I'm very new to ES but have a couple of questions.

Can we see the mapping you used?

What happens if you search using lowercase?

cheers

--  
shaun etherton  
0433 143 761

On Tuesday, 28 August 2012 at 11:04 AM, jackM wrote:

> I have a very simple test case represented here: [http://pastie.org/4600683](http://pastie.org/4600683)
> 
> I am having trouble understanding why the second and third query is not returning the document I have indexed the same way the first query returns the document. Any assistance would be greatly appreciated!
> 
> Note that the first curl statement creates the index (which means I'm using the dynamic mapping functionality.. I can't use a static mapping file, unfortunately).
> 
> --

--

---

<div class="post-metadata">

**Author:** ![Jack\_Markarian](https://avatars.discourse-cdn.com/v4/letter/j/34f0e0/32.png) [@Jack\_Markarian](https://discuss.elastic.co/u/Jack_Markarian)\
**Post date:** [August 28, 2012, 1:46am UTC](https://discuss.elastic.co/t/simple-term-query-problem/8865/3 "2012-08-28T01:46:57Z")

</div>

Wow.. searching with lowercase actually worked! That didn't even cross my  
mind.. I'm going to sit in a corner and feel bad about myself for a  
minute.. Thanks so much for the help, Shaun!

On Monday, August 27, 2012 6:40:36 PM UTC-7, Shaun Etherton wrote:

> Hi,  
> I'm very new to ES but have a couple of questions.
> 
> Can we see the mapping you used?
> 
> What happens if you search using lowercase?
> 
> cheers
> 
> --  
> shaun etherton  
> 0433 143 761
> 
> On Tuesday, 28 August 2012 at 11:04 AM, jackM wrote:
> 
> > I have a very simple test case represented here:  
> > [http://pastie.org/4600683](http://pastie.org/4600683)
> > 
> > I am having trouble understanding why the second and third query is not  
> > returning the document I have indexed the same way the first query returns  
> > the document. Any assistance would be greatly appreciated!
> > 
> > Note that the first curl statement creates the index (which means I'm  
> > using the dynamic mapping functionality.. I can't use a static mapping  
> > file, unfortunately).
> > 
> > --

--

---

<div class="post-metadata">

**Author:** ![Shaun\_Etherton](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/shaun_etherton/32/2540_2.png) [@Shaun\_Etherton](https://discuss.elastic.co/u/Shaun_Etherton)\
**Post date:** [August 28, 2012, 1:51am UTC](https://discuss.elastic.co/t/simple-term-query-problem/8865/4 "2012-08-28T01:51:21Z")

</div>

Haha nah, don't do that..

I spent quite a bit of time reading all the ES document pages and trying to understand what all the bits involved are/mean. Analysers, Stemming etc.. it's all new to me too. 🙂

Glad i could help.

cheers

--  
shaun etherton  
0433 143 761

On Tuesday, 28 August 2012 at 11:16 AM, jackM wrote:

> Wow.. searching with lowercase actually worked! That didn't even cross my mind.. I'm going to sit in a corner and feel bad about myself for a minute.. Thanks so much for the help, Shaun!
> 
> On Monday, August 27, 2012 6:40:36 PM UTC-7, Shaun Etherton wrote:
> 
> > Hi,  
> > I'm very new to ES but have a couple of questions.
> > 
> > Can we see the mapping you used?
> > 
> > What happens if you search using lowercase?
> > 
> > cheers
> > 
> > --  
> > shaun etherton  
> > 0433 143 761
> > 
> > On Tuesday, 28 August 2012 at 11:04 AM, jackM wrote:
> > 
> > > I have a very simple test case represented here: [http://pastie.org/4600683](http://pastie.org/4600683)
> > > 
> > > I am having trouble understanding why the second and third query is not returning the document I have indexed the same way the first query returns the document. Any assistance would be greatly appreciated!
> > > 
> > > Note that the first curl statement creates the index (which means I'm using the dynamic mapping functionality.. I can't use a static mapping file, unfortunately).
> > > 
> > > --  
> > > --

--

---

<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, 3:14am UTC](https://discuss.elastic.co/t/simple-term-query-problem/8865/5 "2017-07-06T03:14:53Z")

</div>


