From the course: Advanced MySQL Database Administration

Unlock this course with a free trial

Join today to access over 25,300 courses taught by industry experts.

Challenge: Deleting records

Challenge: Deleting records

- [Instructor] All right, we're ready for your assignment on deleting records. So, this is one of those examples of a real-world situation that we wish wouldn't happen, but it absolutely does and we need to be prepared for it. For this assignment, Sally, your CEO, is coming to you because you have some bad data in the database. She has a new employee who incorrectly flagged some of the order items as refunds when they were really just customer inquiries. So, that means these items were not actually refunded, but currently in the dataset that you loaded in the previous assignment, these were input into the database. Like I said, this definitely happens in the real world and we need to know how to handle it. So, Sally has come to you and she wants you to remove these order_item_refunds records so that the data can get cleaned up. Some quick hints. Anytime I'm going to be deleting data, I usually run a SELECT * just to see what I'm working with, and just make sure that when you're…

Contents