Deleting data from the database using C

In this recipe, we will learn how to delete information from a database table. We assume that a users table comprising three columns, email_address, passwordand address_of_delivery, already exists (please see the beginning of this chapter, where we created an ecommerce database and a users table in it). You will be prompted to enter the email address of the user whose row has to be deleted. On entering an email address, all the information of the user will be displayed. Thereafter, you will again be asked to confirm if the displayed row should be deleted or not. After your confirmation, the row will be permanently deleted from the table.