Postgresql – Changing the datatype with a custom type in postgres custom data type
I have a custom type in Postgres DB called money_with_currency Created as: CREATE TYPE public.money_with_currency AS (currency_code char(3), amount numeric); We want to change the type of currency_code from char(3) to varchar. I thought the code would be something like:…