In the earlier chapters, we talked about batch and stream data processing APIs provided by Apache Flink. In this chapter, we are going to talk about Table API which is a SQL interface for data processing in Flink. Table API operates on a table interface which can be created from a dataset and datastream. Once the dataset/datastream is registered as a table, we are free to apply relational operations such as aggregations, joins, and selections.
Tables can also be queried like regular SQL queries. Once the operations are performed, we need to convert the table back to either a dataset or datastream. Apache Flink internally uses another open source project called Apache Calcite https://calcite.apache.org/ for optimizing these query transformations.
In this chapter, we are going to cover the following topics:
Registering tables
Accessing the registered table
Operators
Data types
SQL
Now let's get started.
In order to use Table API, the very first thing...