pyflink.table.table_environment.StreamTableEnvironment.create_table#
- StreamTableEnvironment.create_table(path: str, descriptor: pyflink.table.table_descriptor.TableDescriptor)#
Registers the given
TableDescriptor
as a catalog table.The TableDescriptor is converted into a CatalogTable and stored in the catalog.
If the table should not be permanently stored in a catalog, use
create_temporary_table()
instead.Examples:
>>> table_env.create_table("MyTable", TableDescriptor.for_connector("datagen") ... .schema(Schema.new_builder() ... .column("f0", DataTypes.STRING()) ... .build()) ... .option("rows-per-second", 10) ... .option("fields.f0.kind", "random") ... .build())
- Parameters
path – The path under which the table will be registered.
descriptor – Template for creating a CatalogTable instance.
New in version 1.14.0.