rspec/rules/S1139/description.adoc
Arseniy Zaostrovnykh 7ca29f686f Force linebreaks
2021-02-02 15:02:10 +01:00

8 lines
478 B
Plaintext

Executing a ``++DELETE++`` statement without a ``++WHERE++`` clause will delete all rows in a table.
If that is truly what is intended, the ``++TRUNCATE++`` statement should be used because it is faster and uses fewer system and transaction log resources. Moreover when using the ``++TRUNCATE++`` statement, there is no ambiguity about the purpose of the SQL statement.
If removing all content from the table is not what is intended, a ``++WHERE++`` clause should be added.