quiz problems

quiz problems

by shane luffman -
Number of replies: 18
hi all, i have just up graded from moodle 1.5 to 1.6 and when i Preview the quiz i get this error "warningmissingtype" or editmissingtype.. please can anyone shed some light on this for me...thanks shane
Average of ratings: -
In reply to shane luffman

Re: quiz problems

by Alison Wright -
I've had similar stuff like this before and it usually is resolved by installing the latest language pack.  Someone else may be able to confirm this for you.
In reply to Alison Wright

Re: quiz problems

by shane luffman -
hi alison thanks for your help. however i do have the latest lanuage pack installed...shane
In reply to shane luffman

Re: quiz problems

by shane luffman -
i have the latest language pack, as i have updated it via the language admin section which states that "language pack is up to date". i have nealry one hundred quizes. which all have this message in the quize type "warningmissingtype" and the little images qiuze type has gone as well. can anyone please help me with this problem? thanks shane
In reply to shane luffman

Re: quiz problems

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Hi Shane,

There are 2 reasons for your problem.

1. - The warningmissingtype message

If your language pack has been correctly installed & updated, you should be getting this message in your current language, i.e. for English:

This question is of a type that has not been installed on your Moodle yet. Please alert your Moodle administrator.

The bug here comes from a missing parameter in lib\questionlib.php. See bug#6031.

2. - The reason why you are getting this warning message

You are getting this message because the question type of your questions has somehow been changed (corrupted?) to a name which is unknown to Moodle. Tim has suggested that maybe you had created questions of 3rd party question types in your former Moodle installation, but you answered that you did not. Maybe something has happened during migration from 1.5 to 1.6 which has corrupted your database and changed your question types names.

Are you getting the warningmissingtype message for all of the questions in all of your quizzes or only some of them? Could you check your Moodle database (with phpMyAdmin): go to the mdl_question table and look at the qtype column. What can you see there? You should see names such as shortanswer, multichoice, essay, numerical, etc. Anything strange there?

Could you put a few of the offending questions into a category and export that category (using the Moodle XML export format) and post it here so we can examine it?

Hope that helps,

Joseph

In reply to Joseph Rézeau

Re: quiz problems

by shane luffman -
hi thanks for all your help. i have looked at the qtype in the table mdl_question. and in the qtype colum i get numbers from 1 to 8? not shortanswer, multichoice., essay. please can you shed some light on this? ...thanks shane
In reply to shane luffman

Re: quiz problems

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
Now I understand. The question system has changed between Moodle 1.5 and 1.6. In 1.5, question types were numbered from 1 to 8 (in table mdl_quiz_questions, field qtype). In version 1.6, questions reside in table mdl_questions, and their type is written as plain text: multichoice, description, etc.
The problem comes from the procedure you followed to upgrade your Moodle site from 1.5 to 1.6. If all had gone well, then you would find your previously authored questions with their previous question type numbers re-encoded as text labels. Apparently this did not happen for some reason.
What you could do now, if you know your way around the mySql database and phpMyAdmin, is to change those question type numbers to their text equivalent (search & replace). Here is the table of equivalence:

1

shortanswer   

2

truefalse   

3

multichoice   

4

random   

5

match   

6

randomsamatch   

7

description   

8

numerical   

9

multianswer   

10

calculated   

11

rqp   

Hope that helps,
Joseph
In reply to Joseph Rézeau

Re: quiz problems

by shane luffman -
hi Joseph Rézeau, thats done the job, so a big big thank you from filton college. the only problem now is that i have 720 questions to change wink thanks shane
In reply to shane luffman

Re: quiz problems

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
Hi Shane, if you have not already changed your 720 questions by hand, then the mySql command suggested by Tim Hunt here can help.
Joseph
In reply to Joseph Rézeau

Re: quiz problems

by Tim Hunt -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
That is not MYSQL code! That was just a quick and dirty way for me to paste a list of which numbers should change to which strings into the email.
In reply to Tim Hunt

Re: quiz problems

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
Oops, it did look like mySql code/command to me (but I don't know much about mySql language). Sorry. blush
Joseph
In reply to Tim Hunt

Re: quiz problems

by Tony Ruggiero -
Could this be causing my problem:

Tim:

We are running: Moodle 1.6 + (2006050506) on a Linux box. I have some quizes that were created prior to the upgrade and I am trying to move random questions from a test bank into the quiz.

Screenshot:

screen

Realized the screen shot is too small:  "Could not insert new question!"

Any ideas?

Tony
In reply to Tony Ruggiero

Re: quiz problems

by Tim Hunt -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
I don't know. Some things you could try to help diagnose this.
  1. If you create a new course, add a new quiz and create some new questions, can you add the new questions to the new quiz?
  2. If that works, can you add newly created questions to an old quiz, or old questions to a newly created quiz?
  3. If you can, can you make a test install of Moodle 1.6+ from scratch, not by upgrading. If so, does that work?
  4. If you can get a clean install of 1.6, compare the column names and column types in all the mdl_question_... and mdl_quiz_... tables between the clean install and the broken install.
In reply to Tim Hunt

Re: quiz problems

by Tony Ruggiero -
Tim:

I did all of the above. Actually the install was a clean 1.6 install. I can addd questions by selecting them and moving them over but the only feature that's not working is the random selection. I even upgraded to the latest (as of yesterday 7/19) to make sure the code is current.

I will recheck the tables and see if I notice anything.

Thanks,
Tony
In reply to Tony Ruggiero

Re: quiz problems

by Tim Hunt -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
This has been mentioned a couple of time (or mayby just by you several time  smile).

It could well be a genuine issue, but in order for me to investigate it, I would need clear (and hopefully short) sequnce of instructions that start from creating a new course, and then adding a new quiz to it, and which end up with me seeing that error message.

I know it is not easy to produce a repeatable set of instructions like that, but if you could I can probably pin down and fix the problem. Thanks.
In reply to Tim Hunt

Re: quiz problems

by Tony Ruggiero -
Tim:

Could be me several times - it's my split personality. wide eyes

Will do, I will get on it tomorrow when I am more awake.

Thanks,
Tony
In reply to Tony Ruggiero

Re: quiz problems

by kamil zidek -
Could not insert new question!

simply it is problem in , and . some question can be added when i change critical factor from 0,1 to 0.1

in multiply question can be used only 0 or 100% and all works ok

maybe someone know where we can change this , -> .

BRG
Kamil