Open brunodomenici opened 6 years ago
There is a dialect created for SAP Hana DB
io.confluent.connect.jdbc.dialect.SapHanaDatabaseDialect
which extends io.confluent.connect.jdbc.dialect.GenericDatabaseDialect class
The method io.confluent.connect.jdbc.dialect.GenericDatabaseDialect#currentTimestampDatabaseQuery
looks like this:
/**
* Get the query string to determine the current timestamp in the database.
*
* @return the query string; never null or empty
*/
protected String currentTimestampDatabaseQuery() {
return "SELECT CURRENT_TIMESTAMP";
}
I guess that with a PR this could be changed. As I see the SapHanaDatabaseDialect exists since 2016 and I am wondering if it had the issue you're pointing for 2 years.
We are experiencing the same issue while connecting SAP Hana using Kafka connect jdbc. As @mariusneo mentioned above, do we know if its being worked on to update the existing io.confluent.connect.jdbc.dialect.SapHanaDatabaseDialect or please let me know if there is any work around to fix it. Thanks.
Sorry for the delay. I'm not able to test it anymore. I'll close this issue.
We are experiencing the same issue while connecting SAP Hana using Kafka connect jdbc. As @mariusneo mentioned above, do we know if its being worked on to update the existing io.confluent.connect.jdbc.dialect.SapHanaDatabaseDialect or please let me know if there is any work around to fix it. Thanks.
I've created a pull request to fix issue. But sadly it's still under review:( We are using a private build for our product.
Alright, I'm reopening this guys...
There seems to be a patch released( but not merged yet) per https://github.com/confluentinc/kafka-connect-jdbc/pull/692 . When we tried using that JAR keeping the rest of the config/etc. files, we are running into different issue i.e org.apache.kafka.connect.errors.DataException: rowUpdateTimestamp is not a valid field name Here rowUpdateTimestamp is our incremental timestamp column set for timestamp.column.name in config-templates/jdbc-source.properties.template. The said timestamp field is available in HANA and we are able to manually execute the SQL passed to the jdbc-source.properties.template file in the database. Please let me know if you had used that patch version and successfully load incremental data.
Thanks @tlxu, let's hope the Confluent team merge it soon enough
@shoban-kovi can you build Kafka connect on Windows? How did you manage it?
Hi,
I'm trying to configure a source from a SAP HANA View with timestamp increment and I got this error:
It seems that the command generated to get current timestamp (select CURRENT_TIMESTAMP;) doesn't work for HANA. On Hana it could be something like
SELECT CURRENT_TIMESTAMP from dummy
Is it possible to include a configuration parameter to set this query for current timestamp?
Thank you.