# Index format change daily to weekly

**URL:** <https://discuss.elastic.co/t/index-format-change-daily-to-weekly/186656>\
**Category:** Elasticsearch\
**Created:** [June 20, 2019, 10:26am UTC](https://discuss.elastic.co/t/index-format-change-daily-to-weekly/186656 "2019-06-20T10:26:11Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![NAHA](https://avatars.discourse-cdn.com/v4/letter/n/5fc32e/32.png) [@NAHA](https://discuss.elastic.co/u/NAHA)\
**Post date:** [June 20, 2019, 10:26am UTC](https://discuss.elastic.co/t/index-format-change-daily-to-weekly/186656/1 "2019-06-20T10:26:11Z")

</div>

Hi ,

I am currently send logs from NLog to Elasticsearch.  
So , my index format default seems like this - \> " logstash-yyyy.MM.dd"  
I want to change to weekly ,

My Nlog config file like this:

> ```
> <target xsi:type="ElasticSearch" 
> index = "logstash-${date:format=yyyy.MM.dd}"
> layout="${logger} | ${threadid} | ${message}" 
> uri="http://localhost:9200" 
> includeAllProperties ="true">
> </target>
> 
> ```

I tried add index like this :

> index = "logstash-${date:format=xxxx.ww}"

But nothing happened.

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/d/d/dd8b184bf84e3a04a2143ad5035e931f316a8037.png)

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [June 20, 2019, 10:32am UTC](https://discuss.elastic.co/t/index-format-change-daily-to-weekly/186656/2 "2019-06-20T10:32:02Z")

</div>

This seems like an nlog problem not translating that time format, I am not sure if we can help here sorry!

---

<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 18, 2019, 10:32am UTC](https://discuss.elastic.co/t/index-format-change-daily-to-weekly/186656/3 "2019-07-18T10:32:08Z")

</div>

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