Deleting a value in a column can be done in multiple ways in SQL, mileage will always vary. If you have been working in SQL for quite some time and you were able to get the pinch of SQL then single liner statements can be done easily. Deleting a single field or a single value in a column that matches a string or data using SQL is a daunting task, so it's better to practice with a dummy data before executing the statement on a production database or else inadvertent consequences might happen. One liner statement below will delete a value that matches the variable in query. Below is a PHP statemen that will delete a value in a column that matches the variable supplied on the statement. The “.”, dot or period is a concatenation operator for strings in PHP. "DELETE FROM `Table_Name` WHERE column_name = " . " ' " . $variable_query . " ' "; Replace Table_Name with the actual table name and the column_name also with the actual column ...
Make the world a better place by sharing knowledge, ideas and anything that you can give that comes from the heart.