@anonymous-piwik-user opened this issue on March 15th 2008

I found ticket #140 and I have the same error. I didn't modify the database. However, this should probably be logged under a different ticket, but there isn't a create tables script for those of us who don't have permissions to create tables.

I am using: Linux uawww.domain.com 2.6.18-53.1.4.el5 #1 SMP Fri Nov 30 00:45:16 EST 2007 i686 athlon i386 GNU/Linux

php -v PHP 5.1.6 (cli) (built: Sep 20 2007 10:16:10) Copyright (c) 1997-2006 The PHP Group Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies

mysql --help mysql Ver 14.12 Distrib 5.0.22, for redhat-linux-gnu (i686) using readline 5.0 #0 /var/www/html/piwik/plugins/Actions/Actions.php(265): Piwik_DataTable_Row->addColumn('nb_visits', '1') #1 /var/www/html/piwik/plugins/Actions/Actions.php(111): Piwik_Actions->updateActionsTableWithRowQuery(Object(Zend_Db_Statement_Pdo)) #2 function: Piwik_Actions->archiveDay(Object(Event_Notification)) #3 /var/www/html/piwik/libs/Event/Dispatcher.php(280): call_user_func_array(Array, Array) #4 /var/www/html/piwik/libs/Event/Dispatcher.php(250): Event_Dispatcher->postNotification(Object(Event_Notification), true, false) #5 /var/www/html/piwik/modules/PluginsManager.php(422): Event_Dispatcher->post(Object(Piwik_ArchiveProcessing_Day), 'ArchiveProcessi...', Array, true, false) #6 /var/www/html/piwik/modules/ArchiveProcessing/Day.php(69): Piwik_PostEvent('ArchiveProcessi...', Object(Piwik_ArchiveProcessing_Day)) #7 /var/www/html/piwik/modules/ArchiveProcessing.php(237): Piwik_ArchiveProcessing_Day->compute() #8 /var/www/html/piwik/modules/Archive/Single.php(80): Piwik_ArchiveProcessing->loadArchive() #9 /var/www/html/piwik/modules/Archive/Single.php(117): Piwik_Archive_Single->prepareArchive() #10 /var/www/html/piwik/modules/Archive/Single.php(306): Piwik_Archive_Single->get('UserSettings_pl...', 'blob') #11 /var/www/html/piwik/plugins/UserSettings/API.php(108): Piwik_Archive_Single->getDataTable('UserSettings_pl...') #12 function: Piwik_UserSettings_API->getPlugin('1', 'day', '2008-03-15') #13 /var/www/html/piwik/modules/API/Proxy.php(462): call_user_func_array(Array, Array) #14 function: Piwik_API_Proxy->__call('getPlugin', Array) #15 function: Piwik_API_Proxy->getPlugin('1', 'day', '2008-03-15') #16 /var/www/html/piwik/modules/API/Request.php(140): call_user_func_array(Array, Array) #17 /var/www/html/piwik/modules/ViewDataTable.php(352): Piwik_API_Request->process() #18 /var/www/html/piwik/modules/ViewDataTable/Html.php(45): Piwik_ViewDataTable->loadDataTableFromAPI() #19 /var/www/html/piwik/modules/Controller.php(43): Piwik_ViewDataTable_Html->main() #20 /var/www/html/piwik/plugins/UserSettings/Controller.php(114): Piwik_Controller->renderView(Object(Piwik_ViewDataTable_Html), true) #21 /var/www/html/piwik/plugins/UserSettings/Controller.php(11): Piwik_UserSettings_Controller->getPlugin(true) #22 function: Piwik_UserSettings_Controller->index() #23 /var/www/html/piwik/modules/FrontController.php(119): call_user_func_array(Array, Array) #24 /var/www/html/piwik/index.php(62): Piwik_FrontController->dispatch() #25 {main}

@mattab commented on March 17th 2008

does it happen when you select every day? can you give me access to this webserver so I can try to find the bug?

@anonymous-piwik-user commented on March 17th 2008

I get the same error a couple of hours after installing. Please contact me if you like access to our server.

@anonymous-piwik-user commented on March 17th 2008

Sorry... Perhaps an emailadress would make it easier to contact me: david@newsdesk.se

@anonymous-piwik-user commented on March 17th 2008

I had to take piwik offline. After 1 full day of traffic, pulling up any reports took over 5 minutes.

I'm anxious to use it, but the site I'm trying to put it in gets over 5k uniques per day. I had similar luck with phpOpenTracker - just an exorbanant amount of data to track.

@anonymous-piwik-user commented on March 17th 2008

There are currently no indexes on the log tables. I tried to add a few and that made all the difference for me:

CREATE INDEX index_idvisit ON log_link_visit_action (idvisit); CREATE INDEX index_idaction ON log_action (idaction); CREATE INDEX index_idsite ON log_visit (idsite); CREATE INDEX index_visit_server_date ON log_visit (visit_server_date);

Replying to droidmcse:

I had to take piwik offline. After 1 full day of traffic, pulling up any reports took over 5 minutes.

I'm anxious to use it, but the site I'm trying to put it in gets over 5k uniques per day. I had similar luck with phpOpenTracker - just an exorbanant amount of data to track.

@anonymous-piwik-user commented on March 18th 2008

Ok - I put it back online since I got the indexes. I realize that it's a separate issue.

Ok so I am not 100% positive that this won't bite me in the rear, but my site is: www.toolsource.com/piwik username: piwik password: P1w1k1

@mattab commented on March 18th 2008

droidmcse, you should not give passwords to everybody!

I will study the index strategy add add them before the beta

@mattab commented on March 19th 2008

It seems the bug is fixed in the last version. I tried on david box and it works well.

@anonymous-piwik-user commented on March 19th 2008

Using r391.

When accessing index.php without parameters, all widgets except "Last visits graph" display data (no crash, last visits is just empty, probably because Piwik hasn't been able to record anything).

However, if I change to a specific day/week/year, I get this:

Uncaught exception: 'Column nb_visits already in the array!'
More information

In /home/.yana/mikael/mikael.jansson.be/piwik/modules/DataTable/Row.php on line 270
Backtrace:

#0 /home/.yana/mikael/mikael.jansson.be/piwik/plugins/Actions/Actions.php(293): Piwik_DataTable_Row->addColumn('nb_visits', '1')
#1 /home/.yana/mikael/mikael.jansson.be/piwik/plugins/Actions/Actions.php(121): Piwik_Actions->updateActionsTableWithRowQuery(Object(Zend_Db_Statement_Pdo))
#2 /home/.yana/mikael/mikael.jansson.be/piwik/libs/Event/Dispatcher.php(280): Piwik_Actions->archiveDay(Object(Event_Notification))
#3 /home/.yana/mikael/mikael.jansson.be/piwik/libs/Event/Dispatcher.php(250): Event_Dispatcher->postNotification(Array, Array)
#4 /home/.yana/mikael/mikael.jansson.be/piwik/modules/PluginsManager.php(445): Event_Dispatcher->post(Object(Event_Notification), true, false)
#5 /home/.yana/mikael/mikael.jansson.be/piwik/modules/ArchiveProcessing/Day.php(69): Piwik_PostEvent()
#6 /home/.yana/mikael/mikael.jansson.be/piwik/modules/ArchiveProcessing.php(237): Piwik_ArchiveProcessing_Day->compute(Object(Piwik_ArchiveProcessing_Day), 'ArchiveProcessi...', Array, true, false)
#7 /home/.yana/mikael/mikael.jansson.be/piwik/modules/Archive/Single.php(80): Piwik_ArchiveProcessing->loadArchive('ArchiveProcessi...', Object(Piwik_ArchiveProcessing_Day))
#8 /home/.yana/mikael/mikael.jansson.be/piwik/modules/ArchiveProcessing.php(387): Piwik_Archive_Single->prepareArchive()
#9 /home/.yana/mikael/mikael.jansson.be/piwik/modules/ArchiveProcessing.php(233): Piwik_ArchiveProcessing->loadSubperiodsArchive()
#10 /home/.yana/mikael/mikael.jansson.be/piwik/modules/Archive/Single.php(80): Piwik_ArchiveProcessing->loadArchive()
#11 /home/.yana/mikael/mikael.jansson.be/piwik/modules/Archive/Single.php(117): Piwik_Archive_Single->prepareArchive()
#12 /home/.yana/mikael/mikael.jansson.be/piwik/modules/Archive/Single.php(306): Piwik_Archive_Single->get()
#13 /home/.yana/mikael/mikael.jansson.be/piwik/plugins/VisitorInterest/API.php(40): Piwik_Archive_Single->getDataTable()
#14 /home/.yana/mikael/mikael.jansson.be/piwik/modules/API/Proxy.php(462): Piwik_VisitorInterest_API->getNumberOfVisitsPerVisitDuration('VisitorInterest...', 'blob')
#15 [internal function]: Piwik_API_Proxy->__call('VisitorInterest...')
#16 /home/.yana/mikael/mikael.jansson.be/piwik/modules/API/Request.php(140): Piwik_API_Proxy->getNumberOfVisitsPerVisitDuration('1', 'month', '2008-03-18')
#17 /home/.yana/mikael/mikael.jansson.be/piwik/modules/ViewDataTable.php(365): Piwik_API_Request->process(Array, Array)
#18 /home/.yana/mikael/mikael.jansson.be/piwik/modules/ViewDataTable/Cloud.php(44): Piwik_ViewDataTable->loadDataTableFromAPI('getNumberOfVisi...', Array)
#19 /home/.yana/mikael/mikael.jansson.be/piwik/modules/Controller.php(43): Piwik_ViewDataTable_Cloud->main('1', 'month', '2008-03-18')
#20 /home/.yana/mikael/mikael.jansson.be/piwik/plugins/VisitorInterest/Controller.php(32): Piwik_Controller->renderView(Array, Array)
#21 /home/.yana/mikael/mikael.jansson.be/piwik/modules/FrontController.php(122): Piwik_VisitorInterest_Controller->getNumberOfVisitsPerVisitDuration()
#22 /home/.yana/mikael/mikael.jansson.be/piwik/index.php(62): Piwik_FrontController->dispatch()
#23 {main}
@mattab commented on March 19th 2008

Please enable

always_archive_data = true 

in your config/global.ini.php under the

[Debug]

section. try to archive your data again, does it work better? If not send me SSH or FTP access to your piwik installation with write access to your piwik files by email. thanks

@anonymous-piwik-user commented on March 19th 2008

Replying to matt:

Please enable

always_archive_data = true 

in your config/global.ini.php under the

[Debug]

section. try to archive your data again, does it work better?

This is what I'm doing: 1. Go to http://thesite/piwik/index.php 2. Data is displayed for the day 3. Click on "week" 4. Exceptions.

I'm not doing any archiving operation.

If not send me SSH or FTP access to your piwik installation with write access to your piwik files by email. thanks

Hah, as if!

However, if you tell me what data you need to make a minimal test case, I can provide it for you.

@anonymous-piwik-user commented on March 20th 2008

This seems indeed only be happening when I change to another view than day. It still seems to be recording visits, which is good, as the "visit by server time" graph works. The "Last visit graph" is broken, though.

Any ideas on how I can go about debugging this?

@anonymous-piwik-user commented on March 20th 2008

I have exactly the same issue - Uncaught exception: 'Column nb_visits already in the array!'

I've just tried the latest piwik download today but it does not fix anything.

I've tried adding the indexes as suggested above without result, and also changing always_archive_data to true also without result.

Any further suggestions? If I can provide any more info let me know as I'm keen to help this project if I can!

@mattab commented on March 20th 2008

The easiest way to help in this case would be to give me access to your piwik files (ftp or ssh) so I can debug. I promise I won't do anything harmful of course.

@anonymous-piwik-user commented on March 20th 2008

Replying to matt:

The easiest way to help in this case would be to give me access to your piwik files (ftp or ssh) so I can debug. I promise I won't do anything harmful of course.

I can give you the revision of piwik I'm using plus an SQL dump of the piwik tables.

@mattab commented on March 20th 2008

mjbe, please send me your SQL dump at matthieu at piwik .org thanks

@mattab commented on March 22nd 2008

(In [395]) - fix #5566 Column nb_visits already in the array thanks to all for your help! :) - refs #5453 working on this... - split the Record_* classes into several files

This issue was closed on March 22nd 2008
Powered by GitHub Issue Mirror