sql problem
ok i have this bit of code
############TOP country
$getstats_country = $DB_site->query("SELECT userid, username, country FROM user ORDER BY country DESC LIMIT 0, $displayrecords");
while ($getstats_country = $DB_site->fetch_array($getstats_country))
{
eval('$stats_country .= "' . fetch_template('forumhome_stats_country') . '";');
}
but when i run it i get sql error i think its cos the country field is in the userfield its one i added as a profile field its field 8
Database error in vBulletin 3.0.7:
Invalid SQL: SELECT userid, username, country FROM user ORDER BY country DESC LIMIT 0, 10 mysql error: Unknown column 'country' in 'field list'
is it the code or the field 8 i should be calling
the aim is to list the top countrys
thanks for any help
|