![]() | ![]() |
Home |
|
|
Transact-SQL User's Guide |
|
| Chapter 8 Adding, Changing, and Deleting Data |
|
| Deleting all rows from a table |
|
| truncate table syntax |
The syntax of truncate table is:
truncate table [[database.]owner.]table_name
For example, to remove all the data in sales, type:
truncate table sales
Permission to use truncate table, like drop table, defaults to the table owner and cannot be transferred.
A truncate table command is not caught by a delete trigger. See Chapter 16, "Triggers: Enforcing Referential Integrity."
|
|