Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SQL errors on new install #809

Closed
anonymous-matomo-user opened this issue Jun 17, 2009 · 6 comments
Closed

SQL errors on new install #809

anonymous-matomo-user opened this issue Jun 17, 2009 · 6 comments
Labels
Bug For errors / faults / flaws / inconsistencies etc. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical.
Milestone

Comments

@anonymous-matomo-user
Copy link

I install Piwik on Windows / Apache connecting to a CentOS / Mysql 5.0 backend. The install worked fine but the dashboard shows SQL errors because there is no archived data it seems.

The error comes from core/archive/array/IndexedByDate.php in the function getDataTableFromNumeric(). It seems that $archive->getIdArchive(); is returning null and causing a query that looks like this

SELECT value, name, UNIX_TIMESTAMP(date1) as timestamp FROM piwik_archive_numeric_2009_06 WHERE idarchive IN ( ) AND name IN ( 'nb_visits' );

ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') AND name IN ( 'nb_visits' )' at line 1

@anonymous-matomo-user
Copy link
Author

Attachment: Screen shot of the dashboard
ScreenShot.jpg

@robocoder
Copy link
Contributor

Can you grab a snapshot from svn, and run tests/all_tests.php for your set-up?

@robocoder
Copy link
Contributor

Also, what are your versions of Apache, PHP, and MySQL? (major.minor.revision)

@robocoder
Copy link
Contributor

Unable to reproduce. Could this be a timezone mismatch between PHP on the Windows/Apache server and the Centos/MySQL server?

@robocoder
Copy link
Contributor

(In [1268]) Quick fixes #809 - guard against empty archive ID list

@robocoder
Copy link
Contributor

(In [1323]) refs #809 - alternate fix

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical.
Projects
None yet
Development

No branches or pull requests

2 participants