problem wiht sql and quiz packs

All web design discussion, including Ultimate Quiz MOD support.

Moderator: CricketMX Forum Moderators

Post Reply
nuzzosono
Greenhorn
Greenhorn
Posts: 14
Joined: Sun Jul 16, 2006 9:16 am

I have installed quiz mod 1.3.1 in my phpbb forum vers. 2.0.21.

I have an error in the sql process (when i run quiz_install.php)

it can't create a table, the line is this:

CREATE TABLE phpbb_quiz_statistics ( `stats_id` int(5) NOT NULL default '', `quiz_id` int(10) NOT NULL default '', `user_id` int(10) NOT NULL default '', `stats_correct` INT(5) NOT NULL default '0', `stats_incorrect` INT(5) NOT NULL default '0', `stats_percentage` INT(3) NOT NULL default '0');

another problem is that i can't see the quiz pack section in my quiz control pannel the only sections that I see are Quiz permission, quiz configuration and quiz categories.

p.s. I used easymod to install the mod.

thanks in advance for any sugsestion.
nuzzosono
Greenhorn
Greenhorn
Posts: 14
Joined: Sun Jul 16, 2006 9:16 am

Easymod didn't uploaded some files so now the Quiz Packs menu exist.

I still have SQL problem with the statistic table:

DEBUG MODE

SQL Error : 1146 Table 'Sql101055_1.phpbb_quiz_statistics' doesn't exist

SELECT stats_id FROM phpbb_quiz_statistics ORDER BY stats_id DESC LIMIT 1

and now I have a new error when I try to load a quiz pack:

Warning: file_get_contents(http://www.nuzzosono.com/forum/admin/qu ... stralia.qp): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in D:\Inetpub\webs\nuzzosonocom\forum\admin\admin_quiz_packs.php on line 157
User avatar
battye
Site Admin
Site Admin
Posts: 14391
Joined: Sun Jan 11, 2004 8:26 am
Location: Australia
Contact:

Are you using MySQL?
CricketMX.com in 2022: Still the home of bat's, rat's and other farmyard animals!

"OK, life [as you chose to define it] repeats until there are no more lessons to be learned." - nrnoble (June 12, 2005)
"the new forum looks awesome, it's getting bigger & better" - p2p-sharing-rules (11 Jan, 2008)
"Looks like CMX is not only getting bigger...but, also getting better!!" - moongirl (14 Dec, 2007)
nuzzosono
Greenhorn
Greenhorn
Posts: 14
Joined: Sun Jul 16, 2006 9:16 am

yes, but I haven't tryed yet execute the command via mysql admin pannel (I have to retrieve my user/pass)

I only tryed to run quiz_install.php, install button the result is, everything done but the line:

CREATE TABLE phpbb_quiz_statistics ( `stats_id` int(5) NOT NULL default '', `quiz_id` int(10) NOT NULL default '', `user_id` int(10) NOT NULL default '', `stats_correct` INT(5) NOT NULL default '0', `stats_incorrect` INT(5) NOT NULL default '0', `stats_percentage` INT(3) NOT NULL default '0');

regarding my problem with quiz packs, do you think I need to change the permission of some folders to make it work (it seems that from the php code the pack file is not found)

Warning: file_get_contents(http://www.nuzzosono.com/forum/admin/qu ... stralia.qp): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in D:\Inetpub\webs\nuzzosonocom\forum\admin\admin_quiz_packs.php on line 97

Warning: file_get_contents(http://www.nuzzosono.com/forum/admin/qu ... stralia.qp): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in D:\Inetpub\webs\nuzzosonocom\forum\admin\admin_quiz_packs.php on line 157

thanks in advance
User avatar
battye
Site Admin
Site Admin
Posts: 14391
Joined: Sun Jan 11, 2004 8:26 am
Location: Australia
Contact:

It looks like QP_Cities_of_Australia.qp hasn't been uploaded.

Going to http://www.nuzzosono.com/forum/admin/qu ... stralia.qp shows page cannot be found.
CricketMX.com in 2022: Still the home of bat's, rat's and other farmyard animals!

"OK, life [as you chose to define it] repeats until there are no more lessons to be learned." - nrnoble (June 12, 2005)
"the new forum looks awesome, it's getting bigger & better" - p2p-sharing-rules (11 Jan, 2008)
"Looks like CMX is not only getting bigger...but, also getting better!!" - moongirl (14 Dec, 2007)
nuzzosono
Greenhorn
Greenhorn
Posts: 14
Joined: Sun Jul 16, 2006 9:16 am

the file is uploaded (I can see it in my ftp client).

watch this screenshot:

Image

the file is in the pack list, but it seems that it can't be opened.
nuzzosono
Greenhorn
Greenhorn
Posts: 14
Joined: Sun Jul 16, 2006 9:16 am

I think there is something wrong with my hosting (windows).

It seems that some file extension are not propely managed.

If I change the extension from .qp to .txt, I can rech the file by it's address.

Have you heard something like that before?
User avatar
battye
Site Admin
Site Admin
Posts: 14391
Joined: Sun Jan 11, 2004 8:26 am
Location: Australia
Contact:

It could well be a Windows problem, because qp is just an extension I made up (Quiz Packs = qp) and only tested on Windows.

Does it work okay in the ACP as well if you use txt?
CricketMX.com in 2022: Still the home of bat's, rat's and other farmyard animals!

"OK, life [as you chose to define it] repeats until there are no more lessons to be learned." - nrnoble (June 12, 2005)
"the new forum looks awesome, it's getting bigger & better" - p2p-sharing-rules (11 Jan, 2008)
"Looks like CMX is not only getting bigger...but, also getting better!!" - moongirl (14 Dec, 2007)
nuzzosono
Greenhorn
Greenhorn
Posts: 14
Joined: Sun Jul 16, 2006 9:16 am

ok, I modified admin_quiz_packs.php so it look for .txt files, it works.

now I have to create the sql table missed with quiz_install.php

the error i get is this:

DEBUG MODE

SQL Error : 1146 Table 'Sql101055_1.phpbb_quiz_statistics' doesn't exist

SELECT stats_id FROM phpbb_quiz_statistics ORDER BY stats_id DESC LIMIT 1

Line : 31
File : functions_quiz.php

there is another way to generate the table?
nuzzosono
Greenhorn
Greenhorn
Posts: 14
Joined: Sun Jul 16, 2006 9:16 am

I submited the query sql via sql control panel this is the error:

query SQL:

CREATE TABLE phpbb_quiz_statistics(
`stats_id` int( 5 ) NOT NULL default '',
`quiz_id` int( 10 ) NOT NULL default '',
`user_id` int( 10 ) NOT NULL default '',
`stats_correct` INT( 5 ) NOT NULL default '0',
`stats_incorrect` INT( 5 ) NOT NULL default '0',
`stats_percentage` INT( 3 ) NOT NULL default '0'
)

Message of MySQL:

#1067 - Invalid default value for 'stats_id'
nuzzosono
Greenhorn
Greenhorn
Posts: 14
Joined: Sun Jul 16, 2006 9:16 am

the correct value for my database is 'o' now it works fine.
Post Reply