Quote:
Originally Posted by Dean C
Untested:
[sql]
SELECT post.*
awards.*
FROM " . TABLE_PREFIX . "post as post
LEFT JOIN
post
ON
post.userid = award.userid
[/sql]
You didn't give any info on your db schema for the awards table so I'm afraid I can't be of much help other than the query above which may or may not work depending what you have in the awards table 
|
yeah, my mind was just out

the query is kind of simple. Thanks Dean C
The db schema is available in my new hack
https://vborg.vbsupport.ru/showthread.php?t=78934
PHP Code:
$userawards = $DB_site->query("
SELECT a.*, au.*, post.userid, post.postid
FROM " . TABLE_PREFIX . "post, " . TABLE_PREFIX . "award_user au, " . TABLE_PREFIX . "award a
WHERE $postids AND au.userid=post.userid AND a.award_id=au.award_id
GROUP BY au.issue_id
");