hazelcast-jet icon indicating copy to clipboard operation
hazelcast-jet copied to clipboard

Data type conversion failure in INSERT ... SELECT query

Open viliam-durina opened this issue 3 years ago • 0 comments

The following script:

create mapping t type imap options ('keyFormat'='int', 'valueFormat'='varchar');
sink into t select 1, 'a' from table(generate_series(0, 0));

fails with:

Type mismatch [expectedClass=java.lang.Integer, actualClass=java.lang.Byte]

The 1 literal is interpreted as TINYINT, which is Byte, but an Integer is expected in the map m.

This works:

sink into t values(1, 'a')

1 is converted to INTEGER.

viliam-durina avatar Jan 28 '21 15:01 viliam-durina