DB: Support for varchar2 32k

To switch a RAC database in varchar2 32k mode:

sqlplus / as sysdba <<EOF
alter system set cluster_database=false scope=spfile;
alter system set max_string_size=extended scope=spfile;
EOF

srvctl stop database -d <db> -o immediate

sqlplus / as sysdba <<EOF
startup upgrade
@?/rdbms/admin/utl32k

alter session set container=PDB$SEED;
alter system set max_string_size=extended scope=spfile;
@?/rdbms/admin/utl32k

alter session set container=xxx;
alter system set max_string_size=extended scope=spfile;
@?/rdbms/admin/utl32k

alter session set container=cdb$root;
alter system set cluster_database=true scope=spfile;
shutdown immediate;
startup mount;

Beware there is NO invalid materialized view present in the PDB or the upgrade may fail with a similar error as follow:

ORA-00942: table or view does not exist
ORA-06512: at "<PDB>.UTL32K_PARSEQUERY", line 15
ORA-00942: table or view does not exist
ORA-00942: table or view does not exist
ORA-00942: table or view does not exist
ORA-00942: table or view does not exist
ORA-00942: table or view does not exist

ORA-00942: table or view does not exist
ORA-00942: table or view does not exist
ORA-00942: table or view does not exist
ORA-06512: at "SYS.DBMS_SQL", line 1199