# Can I use update statement in jdbc output plugin logstash

**URL:** <https://discuss.elastic.co/t/can-i-use-update-statement-in-jdbc-output-plugin-logstash/321358>\
**Category:** Logstash\
**Created:** [December 16, 2022, 1:41am UTC](https://discuss.elastic.co/t/can-i-use-update-statement-in-jdbc-output-plugin-logstash/321358 "2022-12-16T01:41:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Big\_Man](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/big_man/32/98137_2.png) [@Big\_Man](https://discuss.elastic.co/u/Big_Man)\
**Post date:** [December 16, 2022, 1:41am UTC](https://discuss.elastic.co/t/can-i-use-update-statement-in-jdbc-output-plugin-logstash/321358/1 "2022-12-16T01:41:41Z")

</div>

I need to update specific row in my database.  
Can i use update statement? If yes how do that  
Or any other solution to achieve that.

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [December 16, 2022, 4:21am UTC](https://discuss.elastic.co/t/can-i-use-update-statement-in-jdbc-output-plugin-logstash/321358/2 "2022-12-16T04:21:51Z")

</div>

> [@Big\_Man](#):
>
> Can i use update statement?

As I understand it, [angryangel's jdbc output](https://github.com/theangryangel/logstash-output-jdbc) is a third-party plugin last updated five years ago. The owner archived the github repo. It is not supported by Elastic, and is effectively not supported by anyone else.

But I'm not from Elastic so I'll give you my best guess 😃 The plugin just [prepares the statement and then calls statement.execute](https://github.com/theangryangel/logstash-output-jdbc/blob/aea74f237cfda3b151dae29cf94b44123c2bc408/lib/logstash/outputs/jdbc.rb#L219) so I don't think it cares whether the statement is an INSERT or an UPDATE or anything else.

---

<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:** [January 13, 2023, 4:22am UTC](https://discuss.elastic.co/t/can-i-use-update-statement-in-jdbc-output-plugin-logstash/321358/3 "2023-01-13T04:22:12Z")

</div>

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