pgschema does not detect changes of type when precision or scale is modified.
I have a table as follows:
CREATE TABLE IF NOT EXISTS "public"."my_table" (
"id" "uuid" DEFAULT "gen_random_uuid"() PRIMARY KEY,
"amount" NUMERIC(18,6) NOT NULL DEFAULT 0
);
And I changed it to:
CREATE TABLE IF NOT EXISTS "public"."my_table" (
"id" "uuid" DEFAULT "gen_random_uuid"() PRIMARY KEY,
"amount" NUMERIC(20,6) NOT NULL DEFAULT 0
);
The change is: NUMERIC(18,6) to NUMERIC(20,6).
They are two different types and a change to the column type should be done, however pgschema detects both as the same types and as consequence no change is added to plan.
pgschema does not detect changes of type when precision or scale is modified.
I have a table as follows:
And I changed it to:
The change is:
NUMERIC(18,6)toNUMERIC(20,6).They are two different types and a change to the column type should be done, however pgschema detects both as the same types and as consequence no change is added to plan.