Probeer deze zoekopdracht: SELECT * FROM ( SELECT * FROM table ORDER BY RAND()) t GROUP BY domainname