@@ -183,7 +183,7 @@ begin
183183 from pg_type t
184184 join pg_namespace n on
185185 n.oid = t.typnamespace
186- and not n.nspname in ('pg_catalog', 'information_schema')
186+ and not n.nspname in ('pg_catalog', 'information_schema', '_timescaledb_internal' )
187187 and t.typtype in ('d', 'e', 'r', 'm')
188188 order by t.typname
189189 loop
@@ -217,7 +217,7 @@ begin
217217 from pg_class c
218218 join pg_namespace n on
219219 n.oid = c.relnamespace
220- and not n.nspname in ('pg_catalog', 'information_schema')
220+ and not n.nspname in ('pg_catalog', 'information_schema', '_timescaledb_internal' )
221221 and c.relkind = %L
222222 order by c.relname
223223 $sql$,
@@ -245,7 +245,7 @@ begin
245245 pg_catalog.pg_get_function_identity_arguments(p.oid) as args
246246 from pg_catalog.pg_namespace as n
247247 join pg_catalog.pg_proc as p on p.pronamespace = n.oid
248- where not n.nspname in ('pg_catalog', 'information_schema')
248+ where not n.nspname in ('pg_catalog', 'information_schema', '_timescaledb_internal' )
249249 and p.proname not ilike 'dblink%' -- We do not want dblink to be involved (exclusion)
250250 and p.prokind in ('f', 'p', 'a', 'w')
251251 loop
@@ -273,7 +273,7 @@ begin
273273 select *
274274 from pg_catalog.pg_namespace n
275275 join pg_catalog.pg_ts_dict d on d.dictnamespace = n.oid
276- where not n.nspname in ('pg_catalog', 'information_schema')
276+ where not n.nspname in ('pg_catalog', 'information_schema', '_timescaledb_internal' )
277277 loop
278278 raise debug 'Changing ownership of text search dictionary %.% to %',
279279 r.nspname, r.dictname, new_owner;
@@ -290,7 +290,7 @@ begin
290290 select typname, nspname
291291 from pg_catalog.pg_type
292292 join pg_catalog.pg_namespace on pg_namespace.oid = pg_type.typnamespace
293- where typtype = 'd' and not nspname in ('pg_catalog', 'information_schema')
293+ where typtype = 'd' and not nspname in ('pg_catalog', 'information_schema', '_timescaledb_internal' )
294294 loop
295295 raise debug 'Changing ownership of domain %.% to %',
296296 r.nspname, r.typname, new_owner;
0 commit comments