# Tracking column and Document ID should be same?

**URL:** <https://discuss.elastic.co/t/tracking-column-and-document-id-should-be-same/151583>\
**Category:** Logstash\
**Created:** [October 9, 2018, 9:15am UTC](https://discuss.elastic.co/t/tracking-column-and-document-id-should-be-same/151583 "2018-10-09T09:15:03Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![moneisha](https://avatars.discourse-cdn.com/v4/letter/m/d78d45/32.png) [@moneisha](https://discuss.elastic.co/u/moneisha)\
**Post date:** [October 9, 2018, 9:15am UTC](https://discuss.elastic.co/t/tracking-column-and-document-id-should-be-same/151583/1 "2018-10-09T09:15:03Z")

</div>

There is inserted\_time column and username column in a mysql table. I have to pick the new records daily from mysql.  
I want to use inserted\_time as a tracking column and use sql\_last\_value.  
but inserted\_time is not unique . fields username+inserted\_time is unique.

Now is it possible to have tracking\_column=\> inserted\_time and document\_id=\> username+inserted\_time. Will there be any data loss or data duplicates ?

Do we have to keep both tracking\_column and document\_id as same?

---

<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:** [November 6, 2018, 9:15am UTC](https://discuss.elastic.co/t/tracking-column-and-document-id-should-be-same/151583/2 "2018-11-06T09:15:04Z")

</div>

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