Delete with limit clause in MySQL

Example of Delete with limit Clause in MySQL

DELETE FROM table_name WHERE column_name = column_value LIMIT 1;

Suppose you want to delete the duplicate records from MySQL table then you can use this first count the no of row with duplicate then use -1 with limit clause for delete duplicate records.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.