Christophe Pettus <xof@thebuild.com> writes:
> Is there a way to specify "ucs_basic" (or the other "standard collations" [1]) collation as the default database
collationat database creation time, rather than on a per-column or per-operation basis?
CREATE DATABASE wants you to specify a locale, which ucs_basic is not.
It's defined by SQL as a standard collation name, but that doesn't
make it a complete locale specification. You can do something like
regression=# create database db1 with encoding = 'utf8' locale = 'en_US.utf8' template = template0;
CREATE DATABASE
or
regression=# create database db2 with encoding = 'utf8' icu_locale = 'en-US-x-icu' locale_provider = icu template =
template0;
CREATE DATABASE
or
regression=# create database db3 with encoding = 'utf8' locale = 'POSIX' template = template0;
CREATE DATABASE
regards, tom lane