30 первых пользователей жуйка, которые комментировали ранее, чем заводили свои посты.
=> SELECT (SELECT username FROM users WHERE id = replies.userid),replies.userid FROM replies,threads WHERE replies.userid = threads.userid AND threads.userid = replies.userid GROUP BY threads.userid, replies.userid HAVING MIN(threads.at) > MIN(replies.at) LIMIT 30;
?column? | userid
----------------+--------
Xaber | 29
aduchi | 43
pomkaster2 | 58
me | 105
INFOMAN | 140
Sb | 146
CycaHuH | 191
zm | 197 ?column? | userid
----------------+--------
Xaber | 29
aduchi | 43
pomkaster2 | 58
me | 105
INFOMAN | 140
Sb | 146
CycaHuH | 191
zm | 197
krasniy | 199
Dmitry | 208
alxndrtrofimov | 215
Stasskka | 216
finger | 222
fbt | 223
Toyoku-mono | 234
derFeniX | 252
Milolika | 274
xa4a | 288
umputun | 293
JXLman | 305
Alexey | 315
xander-blr | 335
deboon | 338
Jesus | 357
Arth | 366
nblxa | 373
Avatar | 385
SPlyer | 393
Sealion | 402
vovanium | 408
(30 rows)