Adding a NOT NULL Numeric type to the schema and applying it with Hammer results in an error.
CREATE TABLE Test (
ID STRING(MAX) NOT NULL,
+ A NUMERIC NOT NULL,
) PRIMARY KEY(ID);
$ hammer apply spanner://projects/xxx/instances/yyy/databases/zzz schema.sql
Error: rpc error: code = Unimplemented desc = Cannot add NOT NULL column Test.A to existing table Test.
exit status 1
$ hammer diff spanner://projects/xxx/instances/yyy/databases/zzz ./ddl/schema.sql
ALTER TABLE Test ADD COLUMN A NUMERIC NOT NULL;
ALTER TABLE Test ALTER COLUMN A DROP DEFAULT;
Hammer does not support default values for the Numeric type.
I am expecting the following results.
$ hammer diff spanner://projects/xxx/instances/yyy/databases/zzz ./ddl/schema.sql
ALTER TABLE Test ADD COLUMN A NUMERIC NOT NULL DEFAULT (0);
ALTER TABLE Test ALTER COLUMN A DROP DEFAULT;
Adding a NOT NULL Numeric type to the schema and applying it with Hammer results in an error.
Hammer does not support default values for the Numeric type.
I am expecting the following results.