Describe
Hi,
I defined questions grouped by categories (see here an exercise i created for testing : 11.chamilo.org : exercise with categories).
When i select "random" mode (in "question selection type"), some options doesn't work as they should :
1- "Ordered cat.alpha with questions ordered" : Categories appear in alpha order (it's OK). But questions are not ordered ! Whatever the options selected in this menu below, it never works :
2- "Random categories with questions ordered" : OK for categories. But questions are not ordered (whatever the options selected concerning the categories selected).
3- "Ordered categories alpha with random questions " : everything is ok !
4- "Random categories with random questions" : it seems ok, except with these options (see below)
In this case, questions appear ordered as they are classified by the trainer in his list. Questions are not randomized.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
When a trainer selects "random using categories" and the "questions ordered", questions should be ordered properly.
Additional context
I have the problem with my Chamilo 1.11.10 platform. Reproduced here : 11.chamilo.org : exercise with categories).
Thanks !
Tanchon
Hello @tanchon ,
I have noticed the exercise you are commenting on and I notice that they do not have assigned categories,

I tried to do the test with another exercise that I did https://11.chamilo.org/main/exercise/admin.php?cidReq=CURSO5CATEGORIAS&id_session=0&gidReq=0&gradebook=0&origin=&exerciseId=440


I tried each of the ordering methods of the questions and I couldn't replicate the error you report.
The ordering method is done at the time of starting the test, after it has already been started the order of the tests is not modified even if it is changed by the exercise settings. Therefore, it is necessary to finish the test and try again with the same user.
The exercise you are commenting on cannot be ordered by categories because it does not contain any. Could you try to carry out an exercise where we can replicate the error you are commenting on? Or could you try to check the exercise that I put and tell us?
Thanks Cardangas159 for your answer.
I don't know what happens with my categories.
I've just defined categories, as you can see below
I can confirm everything i reported in my first post. Questions are never ordered as they should. To verify that, you have to make the test until the end, because, sometimes, the first questions are correctly ordered, but not that last questions.
I always defined "all questions" for categories as you can see....
...except for the 4th case (0 everywhere ; -1 in general). As i noticed in my first post, in this case, questions appear ordered as they are classified by the trainer in his list. Questions are not randomized.
Thank you.
My first reaction is that, if you will select all of them anyway, you should probably not select them by category, unless there's some side effect you want to use (like showing the final results table by category). Just select random and select the option to use all questions.
In any case, I am not able to reproduce the issue in the "copy" of the exercise here: https://11.chamilo.org/main/exercise/exercise.php?cidReq=CURSO5CATEGORIAS&id_session=0&gidReq=0&gradebook=0&origin=&
I've also tried with your quiz at https://11.chamilo.org/main/exercise/admin.php?exerciseId=296&cidReq=COURSTANCHON&id_session=0&gidReq=0&gradebook=0&origin= and changed the config to show the results and the question category (although it was already in the question name).
I'm not sure how you do it, but we need a more precise test case to be able to reproduce it ourselves (and fix it).
Hi,
I made a video with your exercise : https://11.chamilo.org/main/exercise/exercise_admin.php?cidReq=CURSO5CATEGORIAS&id_session=0&gidReq=0&gradebook=0&origin=&exerciseId=442
Click here to see the video : https://youtu.be/7XXFH_8Hqsg
As you can see in the video, i selected "ordered cat. alpha with questions ordered"... I only made the video in this configuration but i can reproduce every issues i mentioned in my first post. May be i didn't understand something with "questions ordered" ?...
In the video, we can see that categories are correctly oredered : (1 => 2 => 3).
But into categories, questions are not ordered :
Cat.1 : 2 =>3 =>5=>4=>1 (it should be : 1=>2=>3=>4=>5)
Cat.2 : 5=>4=>1=>2=>3 (it should be : 1=>2=>3=>4=>5)
Cat.3 : 1=>4=>2.... (it should be : 1=>2=>3...)
We can see that questions are not ordered : they seem to appear randomly.
Thanks.
Tanchon.
PS : @Yannick : in some cases, we need to have every questions AND every categories selected, but with questions grouped by categories (because there are logical links between questions). In this case, if (for example) we want that all categories appear randomly with all questions ordered we cannot select random=>use all questions as you suggest (because questions wouldn't be grouped as the teacher want).
Yes, I see I misunderstood your issue description. We will be checking this soon.
@AngelFQC could you review this and close if it solves the issue, please?
I made some quick tests with my quiz : : 11.chamilo.org : exercise with categories
It seems to be ok :-) It's great, because it's a very useful functionality !
Thanks
Tanchon