from pyflink.table import EnvironmentSettings, TableEnvironment

# create a batch TableEnvironment
env_settings = EnvironmentSettings.in_batch_mode()
table_env = TableEnvironment.create(env_settings)

table = table_env.from_elements(
    [(1, 'apple', 200, "a"), 
     (2, 'samsung', 300, "s"),
     (3, 'nokia', 400, "n"),
     (1, 'apple', 300, "a1"), 
     (2, 'samsung', 400, "s1"),
     (3, 'nokia', 500, "n1")
     (1, 'apple', 100, "a2"), 
    ], 
    ['id', 'company', 'price', 'category'])
table.execute().print()