notnull

Library support for Scala's NotNull trait

As far as I understand, if you want a reference type to be non-nullable you have to mixin the magic NotNull trait, and the compiler will automatically prevent you from putting null-able values in it. See this mailing-list thread for instance. What lacking is, a decent library support for non-nullable types. If I would like to write a pa...

How insert a NOT NULL column to an existing table

How to add a column with NOT NULL to an existing table? I have tried like: ALTER TABLE MY_TABLE ADD STAGE INT NOT NULL; But it gives the error message like: "ALTER TABLE only allows columns to be added that can contain nulls or have a DEFAULT definition specified" So, can anyone help me? ...