todayme Posted March 22, 2007 Share Posted March 22, 2007 Could someone please show me how to delete records from mysql. Maybe even an example in a loop that deletes records based on a criteria. Link to comment https://forums.phpfreaks.com/topic/43785-how-do-you-delete-records-from-mysql/ Share on other sites More sharing options...
mem0ri Posted March 22, 2007 Share Posted March 22, 2007 Syntax: DELETE FROM table WHERE condition For more info, go to http://www.mysql.com, click 'documentation', and search for "DELETE SYNTAX" Link to comment https://forums.phpfreaks.com/topic/43785-how-do-you-delete-records-from-mysql/#findComment-212584 Share on other sites More sharing options...
PC Nerd Posted March 22, 2007 Share Posted March 22, 2007 isnt it DROP cant remember whether DROP is for racords of fields goodluck Link to comment https://forums.phpfreaks.com/topic/43785-how-do-you-delete-records-from-mysql/#findComment-212592 Share on other sites More sharing options...
Iceman512 Posted March 22, 2007 Share Posted March 22, 2007 Hi there, Here's an excellent resource for a solid grounding in DELETE for PHP, MySQL: http://www.w3schools.com/php/php_mysql_delete.asp Otherwise, the query will have to look something like this: mysql_query("DELETE FROM Person WHERE LastName='Griffin'"); Regards, Iceman Link to comment https://forums.phpfreaks.com/topic/43785-how-do-you-delete-records-from-mysql/#findComment-212640 Share on other sites More sharing options...
bilis_money Posted March 22, 2007 Share Posted March 22, 2007 drop is deleting the entire table or database. Link to comment https://forums.phpfreaks.com/topic/43785-how-do-you-delete-records-from-mysql/#findComment-212641 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.