Database error

Database error

by Ruben Cancho -
Number of replies: 2

Hi,


I'm new to dataform and I installed from git (release 2.9)  in a current Moodle 3.0.2+ installation (Build: 20160218) . After adding a field and a view I get this error:


Debug info: Unknown column 'e.type' in 'field list'
SELECT e.id, e.dataid, e.state, e.timecreated, e.timemodified, e.userid, e.groupid, e.type , u.id AS uid ,u.picture,u.firstname,u.lastname,u.firstnamephonetic,u.lastnamephonetic,u.middlename,u.alternatename,u.imagealt,u.email,u.idnumber,u.username FROM mdl_dataform_entries e JOIN mdl_user u ON u.id = e.userid WHERE e.dataid = ? ORDER BY e.id ASC
[array (
0 => '7',
)]
Error code: dmlreadexception

Stack trace:
  • line 443 of /lib/dml/moodle_database.php: dml_read_exception thrown
  • line 1080 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()
  • line 371 of /mod/dataform/classes/entry_manager.php: call to mysqli_native_moodle_database->get_records_sql()
  • line 134 of /mod/dataform/classes/entry_manager.php: call to mod_dataform_entry_manager->fetch_entries()
  • line 326 of /mod/dataform/classes/pluginbase/dataformview.php: call to mod_dataform_entry_manager->set_content()
  • line 309 of /mod/dataform/classes/pluginbase/dataformview.php: call to mod_dataform\pluginbase\dataformview->set_entries_content()
  • line 463 of /mod/dataform/classes/dataform.php: call to mod_dataform\pluginbase\dataformview->display()
  • line 71 of /mod/dataform/view.php: call to mod_dataform_dataform->display()
Anyone with the same problem? What could be happening?


Average of ratings: -
In reply to Ruben Cancho

Re: Database error

by Itamar Tzadok -
This is related to a new feature that has not been released yet and does not exist in Dataform 2.9. So you must have taken the code from the master branch which is unstable. If you pull code from git, pull it from one of the release tags at https://github.com/itamart/moodle-mod_dataform/releases. smile
In reply to Itamar Tzadok

Re: Database error

by Ruben Cancho -

You are correct, I did a "git clone" so it's master branch.

ok, I followed your instructions and did a "git checkout tags/v2.9.0".

After reloading the main page a "downgrading error" shows up:


Debug info:
Error code: cannotdowngrade
Stack trace:
  • line 746 of /lib/upgradelib.php: downgrade_exception thrown
  • line 427 of /lib/upgradelib.php: call to upgrade_plugins_modules()
  • line 1647 of /lib/upgradelib.php: call to upgrade_plugins()
  • line 677 of /admin/index.php: call to upgrade_noncore()

I tried to remove completely the plugin and reinstall it again from GUI and now it works!

thank you!