SQL - Remove the duplicate Results
duplicates, sql
Solution
Use `DISTINCT`:
SELECT DISTINCT name, surname
FROM yourtable
WHERE name LIKE '%j%' OR surname LIKE '%j%'
Problem
I have a table that looks like this: ``` name | surname ------------------ John | John Jessica | Madson ``` I have a query like this: ``` SELECT * FROM TABLE WHERE name LIKE '%j%' OR surname LIKE '%j%' ``` What I get: ``` John John John John Jessica Madson ``` What I want: ``` John John Jessica Madson ``` How can I get rid of the duplicate results?