Closed (won't fix)
Project:
Asset API
Version:
5.x-0.1
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Reporter:
Created:
8 Mar 2008 at 12:09 UTC
Updated:
22 Apr 2009 at 13:18 UTC
I found this problem with a fresh install of the module:
user warning: Table 'mydb.aapi_stats' doesn't exist query: SELECT f.*, r.*, s.count FROM files f INNER JOIN file_revisions r ON f.fid = r.fid LEFT JOIN aapi_stats s ON f.fid = s.fid WHERE r.vid = 1 ORDER BY f.fid DESC in /var/www/vhosts/birchermues.li/httpdocs/includes/database.mysql.inc on line 172.
Workaround:
In your database add the table manually:
CREATE TABLE 'aapi_stats' (
fid int(10) unsigned NOT NULL default '0',
count int(10) unsigned NOT NULL default '0',
PRIMARY KEY (fid)
)Problem comes from here:
function aapi_update_20() {
$queries = array();
switch ($GLOBALS['db_type']) {
case 'mysql':
case 'mysqli':
$queries[] = update_sql("CREATE TABLE {aapi_stats} (
fid int(10) unsigned NOT NULL default '0',
count int(10) unsigned NOT NULL default '0',
PRIMARY KEY (fid)
)");
break;
case 'pgsql':
break;
}
return $queries;
}
the hook_update_N() doesn't work. I guess the update number isn't correct according to http://drupal.org/node/136078
Comments
Comment #1
zeropaperComment #2
zeropaper