Search code examples
sqlcreate-tablehana

Create Table Type vs Create Type


enter image description here

Could anyone please describe in simple words about the two statements in this picture ? Your answer would be truly appreciated.

Thanks


Solution

  • Since you are using HANA, it's SQLScript, so:

    CREATE TABLE TYPE is a deprecated syntax for registering table types.

    CREATE TYPE is a new syntax for defining table types. As already mentioned, table types do not have an instance, it's like a template for future use.

    As for the table in the picture, I think it was given to specify differences in an old and new syntax in a nice way.