Re: Need to better way to create JSON If we have TableSchema and Row

2018-07-11 Thread Timo Walther
Hi Shivam, Flink 1.5 provides full Row-JSON-Row conversions. You can take a look at the `flink-json` module. A table schema can be converted into a TypeInformation (Types.ROW(schema.getColumns(), schema.getTypes())) which can be used to configure JsonRowSerialization/DeserializationSchemas.

Re: Need to better way to create JSON If we have TableSchema and Row

2018-07-11 Thread Hequn Cheng
Hi shivam, It seems there is no such a function but you can write one by yourself, maybe use the com.fasterxml.jackson.databind.ObjectMapper. Best, Hequn On Thu, Jul 12, 2018 at 1:56 AM, Shivam Sharma <28shivamsha...@gmail.com> wrote: > Hi All, > > I have TableSchema >

Need to better way to create JSON If we have TableSchema and Row

2018-07-11 Thread Shivam Sharma
Hi All, I have TableSchema object and a Flink Row object(or list). Do we have any straightforward way to convert Row object into JSON by using Schema? For Example:- TableSchema-