{"id":5770,"date":"2021-07-12T23:09:04","date_gmt":"2021-07-12T23:09:04","guid":{"rendered":"https:\/\/swiv.com.br\/performing-application-unistall-tasks\/"},"modified":"2026-05-27T20:02:30","modified_gmt":"2026-05-27T19:02:30","slug":"performing-application-unistall-tasks","status":"publish","type":"post","link":"https:\/\/swiv.com.br\/index.php\/2021\/07\/12\/performing-application-unistall-tasks\/","title":{"rendered":"Performing Application Unistall Tasks"},"content":{"rendered":"\n<p>Neste artigo, vamos simular (ou pelo menos tentar) a desinstala\u00e7\u00e3o de um Application Container em nossa Arquitetura Multitenant.<\/p>\n\n\n\n<p>Logando no container desejado e emitindo o comando abaixo para iniciar o processo de desinstala\u00e7\u00e3o:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n&#x5B;oracle@quiasma ~]$ sqlplus sys\/oracle@HR_AC as sysdba\n \nSQL*Plus: Release 18.0.0.0.0 - Production on Mon Jul 12 19:45:04 2021\nVersion 18.13.0.0.0\n \nCopyright (c) 1982, 2018, Oracle.  All rights reserved.\n \n \nConnected to:\nOracle Database 18c Enterprise Edition Release 18.0.0.0.0 - Production\nVersion 18.13.0.0.0\n \nSQL&gt; ALTER PLUGGABLE DATABASE APPLICATION HR_APP BEGIN UNINSTALL;\n \nPluggable database altered.\n<\/pre><\/div>\n\n\n<p>Realizando o DROP de schema e tablespace:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nSQL&gt; DROP USER HR CASCADE;\n \nUser dropped.\n \nSQL&gt; DROP TABLESPACE HR_TBS INCLUDING CONTENTS AND DATAFILES;\n \nTablespace dropped.\n<\/pre><\/div>\n\n\n<p>Podemos emitir o comando abaixo para encerrar o processo de desinstala\u00e7\u00e3o:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nSQL&gt; ALTER PLUGGABLE DATABASE APPLICATION HR_APP END UNINSTALL;\nALTER PLUGGABLE DATABASE APPLICATION HR_APP END UNINSTALL\n*\nERROR at line 1:\nORA-65344: cannot uninstall or purge an application that has objects, users,\nroles, and profiles\n<\/pre><\/div>\n\n\n<p>Por conta do erro acima, vamos pesquisar quais s\u00e3o os objetos que ainda persistem em nosso Application Container:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \\&quot;wp-block-syntaxhighlighter-code\\&quot;\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nSQL&gt; col object_name format a25\nSQL&gt; col owner format a10\nSQL&gt; SELECT OWNER, OBJECT_NAME, OBJECT_TYPE FROM DBA_OBJECTS WHERE CREATED_APPID IS NOT NULL;\n \nOWNER      OBJECT_NAME               OBJECT_TYPE\n---------- ------------------------- -----------------------\nAUDSYS     SYS_LOB0000018424C00097$$ LOB PARTITION\nAUDSYS     SYS_LOB0000018424C00031$$ LOB PARTITION\nAUDSYS     SYS_LOB0000018424C00030$$ LOB PARTITION\n<\/pre><\/div>\n\n<p>Apesar do meu ambiente estar no \u00faltimo PSU dispon\u00edvel do 18C (18.13), aparentemente me deparei com um Bug que existe desde a vers\u00e3o 12.2, conforme Oracle Note \\&#8221;<strong>12.2 : ORA-65344 error while Uninstalling Application Container (Doc ID 2290928.1)<\/strong>\\&#8221; (link <a rel=\"\\&quot;noreferrer\" noopener\\\"=\"\" href=\"\/%22https:\/\/support.oracle.com\/epmos\/faces\/DocumentDisplay?_afrLoop=151903084074235&#038;id=2290928.1&#038;displayIndex=1&#038;_afrWindowMode=0&#038;_adf.ctrl-state=dfaoeigdb_119%22\" target=\"\\&quot;_blank\\&quot;\">AQUI<\/a>):<\/p>\n\n\n<figure class=\"wp-block-image size-large \\&quot;wp-block-image\"><img decoding=\"async\" src=\"https:\/\/swiv.com.br\/wp-content\/uploads\/2022\/07\/image-36-1024x492.png\" alt=\"\" class=\"wp-image-7532\"\/><\/figure>\n\n\n\n<p>O bug em quest\u00e3o possui um Patch a ser aplicado, mas que est\u00e1 dispon\u00edvel apenas na vers\u00e3o 12.2:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large \\&quot;wp-block-image\"><img decoding=\"async\" src=\"https:\/\/swiv.com.br\/wp-content\/uploads\/2022\/07\/image-1-2-1024x312.png\" alt=\"\" class=\"wp-image-7534\"\/><\/figure>\n\n\n\n<p>A nota cita que caso a vers\u00e3o do database seja diferente dessa, uma SR precisa ser aberta para valida\u00e7\u00e3o do time Oracle.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Neste artigo, vamos simular (ou pelo menos tentar) a desinstala\u00e7\u00e3o de um Application Container em nossa Arquitetura Multitenant. Logando no container desejado e emitindo o comando abaixo para iniciar o processo de desinstala\u00e7\u00e3o: Realizando o DROP de schema e tablespace: Podemos emitir o comando abaixo para encerrar o processo de desinstala\u00e7\u00e3o: Por conta do erro [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[],"class_list":["post-5770","post","type-post","status-publish","format-standard","hentry","category-multitenant"],"_links":{"self":[{"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts\/5770","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/comments?post=5770"}],"version-history":[{"count":1,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts\/5770\/revisions"}],"predecessor-version":[{"id":9081,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/posts\/5770\/revisions\/9081"}],"wp:attachment":[{"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/media?parent=5770"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/categories?post=5770"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/swiv.com.br\/index.php\/wp-json\/wp\/v2\/tags?post=5770"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}