To use a CREATE TYPE
statement in HSQLDB 2.0.0 to create a user-defined type, and to use that user-defined type in a CREATE TABLE
statement.
CREATE TYPE MASK_TYPE AS SMALLINT;
CREATE TABLE MY_TABLE(MY_MASK MASK_TYPE NOT NULL);
When I execute the example, I see the following error message:
type not found or user lacks privilege: MASK_TYPE
Thank you!
The syntax is correct. You need to execute each statement separately.
Update: This does not work with 2.0.0 but works in the latest 2.2.8