How to delete tablespaces that contain materialized views in Oracle

Source: Internet
Author: User
The tablespace deleted today contains materialized view error, ORA-23515: materialized view and/or their indexes exist in the tablespace
It seems that it is necessary to delete the materialized view and perform the delete operation. Because the data is too big and has not been completed for half a day, it is canceled. Check the Internet for another method, delete the user, and specify the cascade parameter, in this way, you can

I tried it.
Drop user user_name cascade;
Deleting a materialized view is faster than deleting a materialized view.

Summary: how to delete tablespaces that contain materialized views
1. Delete the user of the materialized view first
Drop user user_name cascade;
Delete a tablespace
Drop tablespace tablespace_name including contents and datafiles;

2. Delete the materialized view and then the tablespace.
Drop materialized view view_name;
Delete the tablespace.
Drop tablespace tablespace_name including contents and datafiles;

It doesn't matter if the data size is small. If the data size is large, we recommend that you use the first method.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.