@kevinoid opened this Issue on September 24th 2014

Hello Piwik Developers,

I'm currently running Piwik on Debian Wheezy (7.6) with PHP 5.4.4-14+deb7u14. I recently upgraded from 2.0.3 to 2.7.0 by downloading and unzipping http://builds.piwik.org/latest.zip followed by running php piwik/console core:update which produced the following output:

*** Update ***

    Database Upgrade Required

    Your Piwik database is out-of-date, and must be upgraded before you can continue.

    Piwik database will be upgraded from version 2.0.3 to the new version 2.7.0.
    The following dimensions will be updated: log_visit.user_id.

    The database upgrade process may take a while, so please be patient.

    Done!

****************************************
  Piwik has been successfully updated!  
****************************************

After logging in to the web interface I am presented with the following error in most widgets on the dashboard:

WARN CoreHome[2014-09-24 12:28:45] [71e94] Failed to get data from API: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'log_link_visit_action.idaction_content_name' in 'where clause'

Examining the log_link_visit_action table in MySQL yields the following:

mysql> DESCRIBE piwik_log_link_visit_action;
+-------------------------+------------------+------+-----+---------+----------------+
| Field                   | Type             | Null | Key | Default | Extra          |
+-------------------------+------------------+------+-----+---------+----------------+
| idlink_va               | int(11) unsigned | NO   | PRI | NULL    | auto_increment |
| idsite                  | int(10) unsigned | NO   | MUL | NULL    |                |
| idvisitor               | binary(8)        | NO   |     | NULL    |                |
| server_time             | datetime         | NO   |     | NULL    |                |
| idvisit                 | int(10) unsigned | NO   | MUL | NULL    |                |
| idaction_url            | int(10) unsigned | YES  |     | NULL    |                |
| idaction_url_ref        | int(10) unsigned | YES  |     | 0       |                |
| idaction_name           | int(10) unsigned | YES  |     | NULL    |                |
| idaction_name_ref       | int(10) unsigned | NO   |     | NULL    |                |
| idaction_event_category | int(10) unsigned | YES  |     | NULL    |                |
| idaction_event_action   | int(10) unsigned | YES  |     | NULL    |                |
| time_spent_ref_action   | int(10) unsigned | NO   |     | NULL    |                |
| custom_var_k1           | varchar(200)     | YES  |     | NULL    |                |
| custom_var_v1           | varchar(200)     | YES  |     | NULL    |                |
| custom_var_k2           | varchar(200)     | YES  |     | NULL    |                |
| custom_var_v2           | varchar(200)     | YES  |     | NULL    |                |
| custom_var_k3           | varchar(200)     | YES  |     | NULL    |                |
| custom_var_v3           | varchar(200)     | YES  |     | NULL    |                |
| custom_var_k4           | varchar(200)     | YES  |     | NULL    |                |
| custom_var_v4           | varchar(200)     | YES  |     | NULL    |                |
| custom_var_k5           | varchar(200)     | YES  |     | NULL    |                |
| custom_var_v5           | varchar(200)     | YES  |     | NULL    |                |
| custom_float            | float            | YES  |     | NULL    |                |
+-------------------------+------------------+------+-----+---------+----------------+
23 rows in set (0.00 sec)

Looking through the commit history for idaction_content_name brings up ce8d27ce which suggests that perhaps idaction_name was renamed to idaction_content_name although this is not clear.

In addition to fixing this for other users going forward, I'd appreciate some guidance about how to fix this on my system. Should I rename idaction_name to idaction_content_name or simply drop idaction_name and create idaction_content_name?

Thanks,
Kevin

@sgiehl commented on September 24th 2014 Member

That was already reported. See #6280

@kevinoid commented on September 24th 2014

You're right. I'm not sure how I missed it. Sorry about the noise.

This Issue was closed on September 24th 2014
Powered by GitHub Issue Mirror