embulk / embulk-input-jdbc

MySQL, PostgreSQL, Redshift and generic JDBC input plugins for Embulk
Other
102 stars 74 forks source link

Embulk freezes when I specify where condition #177

Open OmkarPathak opened 4 years ago

OmkarPathak commented 4 years ago

Hi team,

I am using embulk-input-oracle for fetching data. This works fine when I write query without any WHERE clause. But when I specify a WHERE clause it just freezes.

This is the config we are using:

in:
  type: oracle
  driver_path: ojdbc7-12.1.0.2.jar
  url: jdbc:oracle:thin:@something.com:1526/DB
  user: ABC
  password: "PASSWORD"
  query: "SELECT * FROM SCHEMA.TABLE WHERE ABC_DATE > to_date('01 JAN 2019','DD MON YY')"
  fetch_rows: 20000
  connect_timeout: 100

Is there any flag to be set for this to work?

hiroyuki-sato commented 4 years ago

Hello, @OmkarPathak

I suspect that SQL doesn't use the index properly.

You can run more verbosely using embulk run -l debug config.yml

OmkarPathak commented 4 years ago

@hiroyuki-sato yes the same query works well in oracle sql. Also tried running verbosely, but it still freezes and no output is generated at sysout (also no error is displayed, and program doesn't exit either)

hiroyuki-sato commented 4 years ago

Hello, @OmkarPathak

hito4t commented 4 years ago

Hi @OmkarPathak Would you show the log until embulk freezes?