# Dots in index and searching

**URL:** <https://discuss.elastic.co/t/dots-in-index-and-searching/194737>\
**Category:** Elasticsearch\
**Created:** [August 11, 2019, 7:43am UTC](https://discuss.elastic.co/t/dots-in-index-and-searching/194737 "2019-08-11T07:43:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![codecandy](https://avatars.discourse-cdn.com/v4/letter/c/ecd19e/32.png) [@codecandy](https://discuss.elastic.co/u/codecandy)\
**Post date:** [August 11, 2019, 7:43am UTC](https://discuss.elastic.co/t/dots-in-index-and-searching/194737/1 "2019-08-11T07:43:36Z")

</div>

Hi,  
I am pretty new to ES: I have to create an index which is dot seperated something like,  
// minions.dev.contents/minion02.retro/noise:2019-08-01T19:42:45.000Z

and the contents is  
//  
{  
"noise" : "25",  
"temperature" : 33,  
"pressure" : 112  
}

where noise:2019-08-01Txxxxx is the ID of the document.

I am trying to do a SQL search  
localhost:9200/\_sql?format=txt  
{  
"query": "SELECT \* FROM 'minions.dev.contents' WHERE noise \< 25"  
}

I am getting an input mismatch exception  
mismatched input ''minions.dev.contents'' expecting {'(',

I am wondering if this is allowed, is there a better practice for storing groups and subgroup and have unique documents based on timestamp ?!

some tips would be helpful  
thanks  
Candy

---

<div class="post-metadata">

**Author:** ![Andrei\_Stefan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/andrei_stefan/32/47533_2.png) [@Andrei\_Stefan](https://discuss.elastic.co/u/Andrei_Stefan)\
**Post date:** [August 12, 2019, 7:03am UTC](https://discuss.elastic.co/t/dots-in-index-and-searching/194737/2 "2019-08-12T07:03:44Z")

</div>

The issue is, in fact, with how you name the index. When reserved characters are used in the name of the index, you should use double quotes. Single quotes and double quotes have different meaning in SQL. More about this [here](https://www.elastic.co/guide/en/elasticsearch/reference/current/sql-lexical-structure.html#sql-syntax-single-vs-double-quotes).

So, your request should look like `"query": "SELECT * FROM \"minions.dev.contents\" WHERE noise < 25"`.

---

<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:** [September 9, 2019, 7:03am UTC](https://discuss.elastic.co/t/dots-in-index-and-searching/194737/3 "2019-09-09T07:03:48Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
