Excample of Create systoolspace in unistaller
Closed this issue · 2 comments
When executing the uninstaller and it fails, it says one should execute a command, but that command depends on the systoolspace.
$ db2 "CALL SYSPROC.ADMIN_DROP_SCHEMA('LOGGER_1B', NULL, 'ERRORSCHEMA', 'ERRORTABLE')"
SQL0443N Routine "ADMIN_DROP_SCHEMA" (specific name "*_DROP_SCHEMA") has
returned an error SQLSTATE with diagnostic text "SYSTOOLSPACE tablespace does
The correct order is:
db2 create tablespace "SYSTOOLSPACE"
db2 DROP TABLE ERRORSCHEMA.ERRORTABLE
db2 "CALL SYSPROC.ADMIN_DROP_SCHEMA('LOGGER_1B', NULL, 'ERRORSCHEMA', 'ERRORTABLE')"
db2 "SELECT * FROM ERRORSCHEMA.ERRORTABLE"
db2 DROP TABLE ERRORSCHEMA.ERRORTABLE
db2 "CALL SYSPROC.ADMIN_DROP_SCHEMA('LOGDATA', NULL, 'ERRORSCHEMA', 'ERRORTABLE')"
db2 "SELECT * FROM ERRORSCHEMA.ERRORTABLE"
db2 "SELECT VARCHAR('db2 DROP PACKAGE LOGGER_1B.' || TRIM(NAME) || ';db2 DROP SCHEMA LOGGER_1B RESTRICT', 128) FROM SYSIBM.SYSPLAN WHERE CREATOR LIKE 'LOG%'"