WEBVTT 0 00:00.550 --> 00:08.560 Now in the last lesson we looked at how to update records in our tables and we looked at the SQL 1 00:08.650 --> 00:10.210 UPDATE statement. 2 00:10.240 --> 00:15.610 Now in this lesson we're going to look at the last letter of CRUD which is DELETE. 3 00:15.610 --> 00:24.460 And if we wanted to delete records then we can simply write DELETE FROM table name where something meets 4 00:24.490 --> 00:26.950 a certain condition. 5 00:26.960 --> 00:33.590 So for example if I want to delete my record of my pencil say if I no longer sell pencils anymore in 6 00:33.590 --> 00:47.030 my shop then I can simply say DELETE FROM products table where the name is equal to pencil or what would 7 00:47.030 --> 00:53.410 be better is if I actually use its id, where id is equal to 2. Now 8 00:53.430 --> 01:00.500 again be careful that you don't run the statement without a WHERE statement because that will delete 9 01:00.860 --> 01:05.870 everything in your products table and you'll end up losing all of the data. 10 01:06.050 --> 01:12.320 So it's again a dangerous statement to execute and make sure that you check your statement before you 11 01:12.320 --> 01:13.860 hit the run button. 12 01:15.150 --> 01:22.800 And now our products table only has one entry left. But through this process you've seen how we can use 13 01:23.070 --> 01:30.990 the Structured Query Language to Create, Read, Update and Delete data from our SQL table.