In MySQL I\'m trying to select any row that matches at least 2 fields of the provided data
Eg. I have been given firstName, lastName, dob, website, email and I want
SELECT (CASE WHEN Field1 = Value1 THEN 1 ELSE 0 END +CASE WHEN Field2 = Value2 THEN 1 ELSE 0 END ... +CASE WHEN FieldN = ValueN THEN 1 ELSE 0 END ) AS Conditions From YourTable WHERE Conditions >= (Min_Number_Of_Fields)