Re: [Table] Types of query result and tablesink do not match error

2019-02-18 Thread Fabian Hueske
Hi François,

I had a look at the code and the GenericTypeInfo checks equality by
comparing the classes the represent (Class == Class).
Class does not override the default implementation of equals, so this is an
instance equality check. The check can evaluate to false, if Map was loaded
by two different classloaders or if you use different implementations of
the interface.

Not sure if this explains the issue you are facing but it's a starting
point.

Best, Fabian

Am Fr., 8. Feb. 2019 um 18:08 Uhr schrieb françois lacombe <
francois.laco...@dcbrain.com>:

> Hi all,
>
> An error is currently raised when using table.insertInto("registeredSink")
> in Flink 1.7.0 when types of table and sink don't match.
>
> I've got the following :
> org.apache.flink.table.api.ValidationException: Field types of query
> result and registered TableSink null do not match.
> Query result schema: [dynamicFields: Map, staticFields: Map]
> TableSink schema:[dynamicFields: Map, staticFields: Map]
> at
> org.apache.flink.table.api.TableEnvironment.insertInto(TableEnvironment.scala:876)
> at org.apache.flink.table.api.Table.insertInto(table.scala:918)
>
> Schemas are the same
> All fields got the GenericType type and I don't understand
> why they are so different.
>
> Have you any additional way to get extra debug information ?
> Any hint ?
>
> All the best
>
> François
>
>
>    
> 
> 
>
> [image: Arbre vert.jpg] Pensez à la planète, imprimer ce papier que si
> nécessaire
>


[Table] Types of query result and tablesink do not match error

2019-02-08 Thread françois lacombe
Hi all,

An error is currently raised when using table.insertInto("registeredSink")
in Flink 1.7.0 when types of table and sink don't match.

I've got the following :
org.apache.flink.table.api.ValidationException: Field types of query result
and registered TableSink null do not match.
Query result schema: [dynamicFields: Map, staticFields: Map]
TableSink schema:[dynamicFields: Map, staticFields: Map]
at
org.apache.flink.table.api.TableEnvironment.insertInto(TableEnvironment.scala:876)
at org.apache.flink.table.api.Table.insertInto(table.scala:918)

Schemas are the same
All fields got the GenericType type and I don't understand
why they are so different.

Have you any additional way to get extra debug information ?
Any hint ?

All the best

François

-- 

       
   



 Pensez à la 
planète, imprimer ce papier que si nécessaire