SQL - Delete
The SQL DELETE statement is used to delete row(s) of data.
Suppose we have a table of students looking like this. The last row is a test record and should be deleted.
Delete from tblStudent where FirstName='TestFirst'
The result is below.
Notice that the action of "DELETE" is permanent. After records are deleted, they are permanently gone. Therefore, you have make sure all the criteria is correct before issuing the DELETE command.
Suppose we have a table of students looking like this. The last row is a test record and should be deleted.
Delete from tblStudent where FirstName='TestFirst'
The result is below.
Notice that the action of "DELETE" is permanent. After records are deleted, they are permanently gone. Therefore, you have make sure all the criteria is correct before issuing the DELETE command.
Comments
Post a Comment