Problem with PHPstatistic 103

Current Version: 1.0.2
Released: 04/25/2010
Post Reply
Danny.l
Newbie
Newbie
Posts: 4
Joined: Sun 20. Mar 2011, 20:06
phpbb.com: Danny L
Location: Lommel / Belgium
Contact:

Problem with PHPstatistic 103

Post by Danny.l »

I've installed the newest version of PHPstatistics (103)
Strange this version is not on this site, because the link in this MOD is to this site.

My question / problem.

The works fine, BUT:
on the tab-"forum activities" and then on user statistics I've got this error-page:

Code: Select all

Algemene fout
SQL ERROR [ mysqli ]

Unknown column 'user_type' in 'where clause' [1054]

SQL

SELECT (MAX(user_id) - (MAX(user_id) - COUNT(user_id))) AS total FROM phpbb_users WHERE user_type <> 1

BACKTRACE


FILE: includes/db/mysqli.php
LINE: 163
CALL: dbal->sql_error()

FILE: statistics/includes/functions.php
LINE: 827
CALL: dbal_mysqli->sql_query()

FILE: includes/stats/stats_activity.php
LINE: 442
CALL: get_total_members()

FILE: includes/functions_module.php
LINE: 507
CALL: stats_activity->main()

FILE: stats.php
LINE: 71
CALL: p_master->load_active()



This is the link were I found the MOD:
http://www.phpbb.com/customise/db/mod/phpbb_statistics
Can someone please tell me what the problem is?
Anything else works fine :?
User avatar
Marc
Administrator
Administrator
Posts: 620
Joined: Tue 2. Sep 2008, 22:48
phpbb.com: Marc
Location: Munich
Contact:

Re: Problem with PHPstatistic 103

Post by Marc »

If you do not have the column user_type, then something is wrong with your forum.
Image
Danny.l
Newbie
Newbie
Posts: 4
Joined: Sun 20. Mar 2011, 20:06
phpbb.com: Danny L
Location: Lommel / Belgium
Contact:

Re: Problem with PHPstatistic 103

Post by Danny.l »

I do have the column user_group
I've made a printscreen
printscreen
printscreen
user_group.png (44.72 KiB) Viewed 39164 times
User avatar
Marc
Administrator
Administrator
Posts: 620
Joined: Tue 2. Sep 2008, 22:48
phpbb.com: Marc
Location: Munich
Contact:

Re: Problem with PHPstatistic 103

Post by Marc »

The table it selects from is phpbb3_users in your case. ;)
Image
Danny.l
Newbie
Newbie
Posts: 4
Joined: Sun 20. Mar 2011, 20:06
phpbb.com: Danny L
Location: Lommel / Belgium
Contact:

Re: Problem with PHPstatistic 103

Post by Danny.l »

My complete database is like phpBB3_xxxxxx, this is because I specified it this way.
Al the extra colomn added for this MOD are also phpBB3_xxxx, no furter problem....
But I don't have a column phpBB3_user_type :o
Must I create one?
How comes I don't have this, do I need it?
My forum is working perfect, I don't see anywhere else a problem.
Last edited by Danny.l on Sat 26. Mar 2011, 11:45, edited 1 time in total.
User avatar
Marc
Administrator
Administrator
Posts: 620
Joined: Tue 2. Sep 2008, 22:48
phpbb.com: Marc
Location: Munich
Contact:

Re: Problem with PHPstatistic 103

Post by Marc »

Now I get what your error is, I guess that error message is kind of unexpected. Anyhow, apply the change to statistics/includes/functions.php:
https://github.com/marc1706/phpBB-Stati ... 1.0#diff-1
Image
Danny.l
Newbie
Newbie
Posts: 4
Joined: Sun 20. Mar 2011, 20:06
phpbb.com: Danny L
Location: Lommel / Belgium
Contact:

Re: Problem with PHPstatistic 103

Post by Danny.l »

Thankx, this did it.
Post Reply