Help Center > > Developer Guide> SQL Reference> SQL Syntax> DROP FOREIGN TABLE

DROP FOREIGN TABLE

Updated at: Mar 13, 2020 GMT+08:00

Function

DROP FOREIGN TABLE deletes a specified foreign table.

Precautions

DROP FOREIGN TABLE forcibly deletes a specified table. After a table is deleted, any indexes that exist for the table will be deleted. The functions and stored procedures used in this table cannot be run.

Syntax

1
2
DROP FOREIGN TABLE [ IF EXISTS ] 
    table_name [, ...] [ CASCADE | RESTRICT ];

Parameter Description

  • IF EXISTS

    Sends a notice instead of an error if the specified table does not exist.

  • table_name

    Specifies the name of the table.

    Value range: An existing table name.

  • CASCADE | RESTRICT
    • CASCADE: automatically deletes all objects (such as views) that depend on the table to be deleted.
    • RESTRICT: refuses to delete the table if any objects depend on it. This is the default.

Examples

See Examples and Examples for CREATE FOREIGN TABLE.

Did you find this page helpful?

Submit successfully!

Thank you for your feedback. Your feedback helps make our documentation better.

Failed to submit the feedback. Please try again later.

Which of the following issues have you encountered?







Please complete at least one feedback item.

Content most length 200 character

Content is empty.

OK Cancel