Import question as new version

Question bank plugins ::: qbank_importasversion
Maintained by TimTim Hunt, Andreas Steiger
This plugin allows you to import a question from a Moodle XML file as a new version of an existing question.
Latest release:
147 sites
61 downloads
13 fans
Current versions available: 1

Once this plugin is installed, in the question bank, in the action menu for each question, there is a new option 'Import a new version'. If you choose that, you see a form where you can upload a Moodle XML file containing a single question. If possible (e.g. if the question type matches) then that question is imported as the latest version of this question. (This is different from the standard way of importing questions, which always creates new questions.)

Screenshots

Screenshot #0
Screenshot #1
Screenshot #2

Contributors

Tim
Tim Hunt (Lead maintainer)
Andreas Steiger: Developer
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
  • Plugins bot
    Wed, 14 June 2023, 11:00 PM
    Approval issue created: CONTRIB-9305
  • Martin Latschenberger
    Wed, 27 Mar 2024, 11:36 PM
    Hello Tim and Andreas,
    your Plugin is wonderful but unfortunately not working for questions of type CLOZE.
    I did already an entry in the Bug Tracker.
    Hoping for a quick fix.
    Thank you
    Martin
  • Alex F
    Thu, 5 June 2025, 2:15 PM
    Hi there,
    Is the documentation at https://github.com/maths/moodle-qbank_importasversion correct in that this plugin can only import a single question as a new version of an existing question at once? It would be very useful for us if the plugin could import multiple question instances at once, matching them based on name, type, and category, because the way we write our (statistics) questions follows the following workflow:
    - We generate multiple (fixed) instances of a question (using an R package called R/Exams). The R/Exams package puts these question instances into an XML file.
    - We then import the XML file containing these question instances into Moodle.
    - Even though these fixed instances all correspond to the same question, they appear as separate (fixed) questions in the Moodle bank.
    - We need to import multiple questions at once here, as randomisation of the question instances students see is achieved by using the select random question functionality (as each question instance itself is fixed and has no randomisation).
    If we have an issue with a question (and all it's instances) in a live assignment, the only way we could fix this (other than to go through and edit each question instance manually!) would be to import all the question instances as new versions of the existing question instances, so would involve being able to import multiple questions at once as new versions of existing questions.
    Is doing this possible with this plugin at the moment, and if not, would adapting the plugin to allow the importing of multiple questions as new versions of existing questions at once be possible?
    Many thanks,
    Alex
  • Andreas Steiger
    Fri, 6 June 2025, 4:20 PM
    Hi Alex,
    Yes, it is correct that this plugin can only import a version for a single question. We are aware that it would be useful to do have a multiple question feature. But it would also be a much more complicated plugin, and neither of us has the time to design, develop or maintain that -- Sorry!
    The good news is that there is another plugin for managing larger Moodle question banks: https://github.com/maths/moodle-qbank_gitsync. qbank_gitsync builds on top of qbank_importasversion, and based on your problem description, it sounds like qbank_gitsync could be useful for you.
    Best
    Andreas
Please login to post comments