# Date format in Elastic search mapping template creation

**URL:** https://discuss.elastic.co/t/date-format-in-elastic-search-mapping-template-creation/1994
**Category:** Elasticsearch
**Created:** [June 5, 2015, 8:26am UTC](https://discuss.elastic.co/t/date-format-in-elastic-search-mapping-template-creation/1994 "2015-06-05T08:26:19Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Suganthi\_Thangavel](https://avatars.discourse-cdn.com/v4/letter/s/bcef8e/32.png) [@Suganthi\_Thangavel](https://discuss.elastic.co/u/Suganthi_Thangavel)
#### Post date: [June 5, 2015, 8:26am UTC](https://discuss.elastic.co/t/date-format-in-elastic-search-mapping-template-creation/1994/1 "2015-06-05T08:26:19Z")

</div>

Hi ,

I have time field in my csv to pass to kibana. What is the format that i have to use in elastic search mapping template ting HH:mm:ss.SSS as time field in kibana . I used the below one which i got from Elastic search date formats URL "[https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-date-format.html](https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-date-format.html)"

curl -XPUT 10.210.91.108:9200/\_template/test2 -d '{  
"template": "hmtindex2\*",  
"settings": {  
"number\_of\_shards": 1,  
"number\_of\_replicas": 0,  
"index.refresh\_interval": "5s"  
},  
"sort": {  
"elapsed": {  
"order": "asc",  
"ignore\_unmapped": true  
}  
},  
"mappings": {  
"logs": {  
"properties": {   
"Hierarchy\_Name": {  
"type": "string"  
},  
"RetrieveTime": {  
"format": "HH:mm:ss.SSS",  
"type": "date"  
},  
"cont": {  
"type": "integer"  
},  
"col1": {  
"type": "integer"  
}  
}  
}  
}  
}  
}'

But In kibana "RetrieveTime" comes as "string" field help me,

---

<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:09am UTC](https://discuss.elastic.co/t/date-format-in-elastic-search-mapping-template-creation/1994/2 "2017-07-06T00:09:28Z")

</div>


