If I have the following table:
my_table:
varchar name
int score
and I want to do the following query:
select name from my_table group by name having count(*)>3
union
select name from my_table where name like '%xyz'
Is there a way doing this query without a union?
To be clear: I want all names which have more than three entries in the table OR answer the like clause '%xyz'
.