Hi, you can also use the CsvTableSource and read the DateTime fields as String. This will directly give you a table. You can implement a user-defined scalar function [1] to parse the String into a DateTime type.
The benefit is that you stay in the Table API / SQL and don't have to deal with the DataSet or DataStream API and the conversion. Best, Fabian [1] https://ci.apache.org/projects/flink/flink-docs-release-1.2/dev/table_api.html#user-defined-scalar-functions 2017-02-07 3:16 GMT+01:00 nsengupta <sengupta.nirma...@gmail.com>: > Hello Timo, > > Thanks for the clarification. > > This means that I *cannot use CsvTableSource*, as I have, in the example. > Instead, I should: > > * Write custom Scalar function to convert STRINGs to other datatypes as > required > * Read the file as CsvInput, with all fields as STRINGs > * Apply the Scalar function as approrpiate and Map() to a desired a > *DataSet* type > * /Convert/ the DataSet to a Table > * Use SQL to access the Table > > Is my understanding correct? > > -- Nirmalya > > > > -- > View this message in context: http://apache-flink-user- > mailing-list-archive.2336050.n4.nabble.com/Table-API-java- > sql-DateTime-is-not-supported-tp11439p11480.html > Sent from the Apache Flink User Mailing List archive. mailing list archive > at Nabble.com. >