# How can we import only new/updated records if there is no unique/timestamp in sql server (using logstash)

**URL:** <https://discuss.elastic.co/t/how-can-we-import-only-new-updated-records-if-there-is-no-unique-timestamp-in-sql-server-using-logstash/201421>\
**Category:** Logstash\
**Created:** [September 27, 2019, 3:02pm UTC](https://discuss.elastic.co/t/how-can-we-import-only-new-updated-records-if-there-is-no-unique-timestamp-in-sql-server-using-logstash/201421 "2019-09-27T15:02:55Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![rameshkr1994](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rameshkr1994/32/59029_2.png) [@rameshkr1994](https://discuss.elastic.co/u/rameshkr1994)\
**Post date:** [September 27, 2019, 3:02pm UTC](https://discuss.elastic.co/t/how-can-we-import-only-new-updated-records-if-there-is-no-unique-timestamp-in-sql-server-using-logstash/201421/1 "2019-09-27T15:02:55Z")

</div>

Dear All.

i have some data in sql server side but there is no any unique records there but  
we want to import only newly / updated data from sql server to elastic search as index .

please help for this use case.

Thanks  
HadoopHelp

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [September 27, 2019, 4:12pm UTC](https://discuss.elastic.co/t/how-can-we-import-only-new-updated-records-if-there-is-no-unique-timestamp-in-sql-server-using-logstash/201421/2 "2019-09-27T16:12:45Z")

</div>

You need to be able to write a query that at any point extracts only new records. This generally requires a time stamp or sequence number, so without that I think it will be hard.

---

<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:** [October 25, 2019, 4:12pm UTC](https://discuss.elastic.co/t/how-can-we-import-only-new-updated-records-if-there-is-no-unique-timestamp-in-sql-server-using-logstash/201421/3 "2019-10-25T16:12:48Z")

</div>

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