Mysql - Preventing duplicate entries of combined columns with Unique Index
问题 I have an issue with duplicate entries in a database and due to the nature of the problem the easiest way to fix it would be to remove current duplicate rows and prevent further duplicates from being added . Here is the table structure : | a | b | c | user url1 token1 photo url1 token2 action action1 token3 user url1 token4 photo url1 token5 action action2 token6 I want to prevent duplicate entries only when 2 columns are duplicated, in this case a and b . So here we have user | url1 and