Drop extensions in Azure HorizonDB

Before dropping extensions in an Azure HorizonDB cluster, add them to the allow list.

Steps to drop extensions

  1. Add the extension to the allow list.

  2. The user that drops the extensions must be a member of the azure_pg_admin role.

  3. Run the DROP EXTENSION command to drop or uninstall a particular extension. This command removes the objects packaged in the extension from your database.

    DROP EXTENSION <extension>;
    
  4. Some extensions might distribute objects required by other extensions. For example, pg_diskann depends on vector extension. To drop such extensions, you can proceed in two ways:

    DROP EXTENSION <dependent_extension>;
    DROP EXTENSION <depending_extension>;
    
    • Allow extensions in Azure HorizonDB and run DROP EXTENSION on the extension that you want to drop. Add CASCADE to also drop objects that depend on the extension, including other extensions. Review those dependencies and recovery options before using it.
    DROP EXTENSION <depending_extension> CASCADE;