Open topic with navigation

TIBCO ActiveSpaces® - Enterprise Edition 5.0.0

# The SQL DELETE Statement

A SQL DELETE statement removes rows of data from a table. If the DELETE activity is successful, it returns the number of rows removed from the table.

If the DELETE activity is not successful, 0 is returned as the number of rows removed from the table.

Transactions are not supported for DELETE statements and you cannot create a DELETE statement from a transacted session.

Since transactions are not supported with DELETE, if an error occurs while performing row deletion, any rows already deleted remain deleted and the delete is not rolled back.

## Syntax

    DELETE FROM <table_name> [ AS <alias> ] [ <WHERE clause> ]

Where

- `table_name`: Name of the table in which the rows are removed.
- `alias`: A temporary name for the table that is used to make the table name more readable.
- `WHERE clause`: An expression that starts with the keyword 'WHERE' and results in a boolean value that indicates whether a row should be removed. If omitted, all rows of the table are removed. For more information, see The WHERE Clause.

Warning: If a WHERE clause is omitted from a DELETE statement, all rows in the table are removed. For information on how to prevent the inadvertent removal of rows by DELETE statements without a WHERE clause, see the full_table_delete table and grid properties.
Subtopics

Did you find this helpful?

Yes No
Great!
Thanks for taking the time to give us some feedback.
Sorry about that

Why wasn't this helpful? (check all that apply)

Could not find what I was looking for
Instructions confusing or unclear
Instructions did not work

Want to tell us more?

Please select at least one option or provide details about the issue!!

Error occurred while submitting feedback.

Error2 occurred while submitting feedback.

TIBCO ActiveSpaces® - Enterprise Edition

Copyright © 2009-2025. Cloud Software Group, Inc. All Rights Reserved.