Achilleus
Achilleus

Reputation: 1944

Kafka connect JDBC connector

I am trying to use io.confluent.connect.jdbc.JdbcSourceConnector in bulk mode using the query .

query = select name, cast(ID as NUMBER(20,2)),status from table_name

Is this possible? If possible am I missing something? I am getting

exception (org.apache.kafka.connect.runtime.WorkerTask:148)
org.apache.avro.SchemaParseException: Illegal character in: CAST(IDASNUMBER(20,2))

Upvotes: 0

Views: 387

Answers (1)

TobiSH
TobiSH

Reputation: 2921

Use an alias for the 2nd column. This alias must be the name of the target avro-field.

Upvotes: 1

Related Questions