Reputation: 9915
In Flink 1.15, I want to read a column that is typed with the Postgres UUID type (the id
column).
However, this does not work; crashes with The PostgreSQL dialect doesn't support type: RAW('java.lang.String', '...') NOT NULL
. How can I interpret all id
results as a plain string?
DataTypes.STRING()
doesn't work.columnByExpression("id", "CAST(
id AS VARCHAR(32))")
doesn't work.columnByExpression("id", "\"id\"::varchar")
doesn't workUpvotes: 2
Views: 479
Reputation: 9915
TableDescriptor.forConnector("jdbc")
.schema(
Schema.newBuilder()
.column("app_id", DataTypes.STRING().notNull())
.column("moniker", DataTypes.STRING().notNull())
.columnByExpression("a_proctime", "PROCTIME()")
.primaryKey("app_id")
.build())
Upvotes: 2