SELECT t1_1.id, t1_1.id_s, t1_1.navn, t1_1timestamp, t2.tlf FROM tabel_1 t1_1 JOIN tabel2 t2 ON t1_1.id_d = t2.id_s WHERE timestamp = (SELECT MAX(timestamp) FROM tabel_1 t1_2 WHERE t1_2.id_s = t1_1.id_s) AND under = (SELECT MAX(under) FROM tabel_1 t1_3 WHERE t1_3.id_s = t1_1.id_s)
SELECT t1_1.id, t1_1.id_s, t1_1.navn, t1_1timestamp, t2.tlf FROM tabel_1 t1_1 JOIN tabel2 t2 ON t1_1.id_d = t2.id_s WHERE timestamp = (SELECT MAX(timestamp) FROM tabel_1 t1_2 WHERE t1_2.id_s = t1_1.id_s) OR under = (SELECT MAX(under) FROM tabel_1 t1_3 WHERE t1_3.id_s = t1_1.id_s)
Tilladte BB-code-tags: [b]fed[/b] [i]kursiv[/i] [u]understreget[/u] Web- og emailadresser omdannes automatisk til links. Der sættes "nofollow" på alle links.