# JDBC input plugin - no results from oracle db

**URL:** <https://discuss.elastic.co/t/jdbc-input-plugin-no-results-from-oracle-db/93567>\
**Category:** Logstash\
**Created:** [July 18, 2017, 11:30am UTC](https://discuss.elastic.co/t/jdbc-input-plugin-no-results-from-oracle-db/93567 "2017-07-18T11:30:07Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![mato848](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mato848/32/20169_2.png) [@mato848](https://discuss.elastic.co/u/mato848)\
**Post date:** [July 18, 2017, 11:30am UTC](https://discuss.elastic.co/t/jdbc-input-plugin-no-results-from-oracle-db/93567/1 "2017-07-18T11:30:07Z")

</div>

Hi everyone,  
I am trying to read some data from Oracle 11g database. My configuration is working, but only until some id.  
For example following statement produces results into output

```auto
select * from sys_log where id > 10 and rownum < 10
```

But this statement not. Even when data are present in DB

```auto
select * from sys_log where id > 40900 and rownum < 10
```

It looks like db client fetches some data on start and doesn't give results for data outside this result set.  
There are no error in the console. I am using logstash 5.5.0

here is my configuration

```auto
input { 
   stdin { }

    jdbc {
    jdbc_driver_library => "ojdbc7-12.1.0.2.jar"
    jdbc_driver_class => "Java::oracle.jdbc.OracleDriver"
    jdbc_connection_string => "jdbc:oracle:thin:@127.0.0.1:1523/DBSID"
    jdbc_user => "user"
    jdbc_password => "password"
    schedule => "* * * * *"
    statement => "select * from sys_log where id > 40900 and rownum < 10"
  }
 }
output {
  stdout { codec => rubydebug }
}
```

Can someone please help to determine if its a bug or if there is something wrong with my configuration ?  
Thanks 🙂

---

<div class="post-metadata">

**Author:** ![Mr.Flakes](https://avatars.discourse-cdn.com/v4/letter/m/e480ec/32.png) [@Mr.Flakes](https://discuss.elastic.co/u/Mr.Flakes)\
**Post date:** [July 18, 2017, 12:30pm UTC](https://discuss.elastic.co/t/jdbc-input-plugin-no-results-from-oracle-db/93567/2 "2017-07-18T12:30:38Z")

</div>

Since you stated that first statement produces results and second does not could it be a problem with the DB? Are you sure that data for the second statement is already commited and all other sessions can see that data?

---

<div class="post-metadata">

**Author:** ![mato848](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mato848/32/20169_2.png) [@mato848](https://discuss.elastic.co/u/mato848)\
**Post date:** [July 18, 2017, 2:24pm UTC](https://discuss.elastic.co/t/jdbc-input-plugin-no-results-from-oracle-db/93567/3 "2017-07-18T14:24:35Z")

</div>

Yes everything is commited. Actually i don't do any changes on the table.  
Also i don't think there is something wrong wit the DB. I use it for other projects and everything works fine.

---

<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:** [August 15, 2017, 2:24pm UTC](https://discuss.elastic.co/t/jdbc-input-plugin-no-results-from-oracle-db/93567/4 "2017-08-15T14:24:41Z")

</div>

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