Update Forum Post / Restore

Re: Update Forum Post / Restore

by Helson C -
Number of replies: 2

We need the logs, because the restore is for moodle backup of all courses.


We have a moodle only for restore courses of previous year, to query when necessary.

Then in this way we can't restore without logs, because the report use the logs to create statistics 

that for us is very important.



In reply to Helson C

Re: Update Forum Post / Restore

by Helson C -

Same error again:

Debug info: ERROR: invalid input syntax for integer: "{forum_discussion}#p{forum_post}"
SELECT * FROM mdl_backup_ids_temp WHERE backupid = $1 AND itemname = $2 AND itemid = $3
[array (
0 => 'd61cbe080aa7c5a3a4e4c57e8954815a',
1 => 'forum_discussion',
2 => '{forum_discussion}#p{forum_post}',
)]

In reply to Helson C

New error

by Helson C -

Debug info: ERROR: null value in column "questionid" violates not-null constraint
INSERT INTO mdl_question_attempts (slot,behaviour,questionid,variant,maxmark,minfraction,maxfraction,flagged,questionsummary,rightanswer,responsesummary,timemodified,questionusageid) VALUES($1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13) RETURNING id
[array (
'slot' => '1',
'behaviour' => 'deferredfeedback',
'questionid' => NULL,
'variant' => '1',
'maxmark' => '1.0000000',
'minfraction' => '0.0000000',
'maxfraction' => '1.0000000',
'flagged' => '0',
'questionsummary' => 'O útero tem como origem embriológica:: ductos de Wolff ou ductos mesonéfricos 

 ; ductos de Wolff e cristas gonadais; ductos mesonéfricos e o primórdio uterovaginal; o mesênquima e o ducto de Wolff; ductos de Müller ou ductos paramesonéfricos',
'rightanswer' => 'ductos de Müller ou ductos paramesonéfricos',
'responsesummary' => 'ductos de Müller ou ductos paramesonéfricos',
'timemodified' => 1457051482,
'questionusageid' => 3649,
)]
Error code: dmlwriteexception
Stack trace:
  • line 446 of /lib/dml/moodle_database.php: dml_write_exception thrown
  • line 243 of /lib/dml/pgsql_native_moodle_database.php: call to moodle_database->query_end()
  • line 852 of /lib/dml/pgsql_native_moodle_database.php: call to pgsql_native_moodle_database->query_end()
  • line 904 of /lib/dml/pgsql_native_moodle_database.php: call to pgsql_native_moodle_database->insert_record_raw()
  • line 4152 of /backup/moodle2/restore_stepslib.php: call to pgsql_native_moodle_database->insert_record()
  • line 4083 of /backup/moodle2/restore_stepslib.php: call to restore_questions_activity_structure_step->restore_question_attempt_worker()
  • line 137 of /backup/util/plan/restore_structure_step.class.php: call to restore_questions_activity_structure_step->process_question_attempt()
  • line 103 of /backup/util/helper/restore_structure_parser_processor.class.php: call to restore_structure_step->process()
  • line 151 of /backup/util/xml/parser/processors/grouped_parser_processor.class.php: call to restore_structure_parser_processor->dispatch_chunk()
  • line 91 of /backup/util/helper/restore_structure_parser_processor.class.php: call to grouped_parser_processor->postprocess_chunk()
  • line 148 of /backup/util/xml/parser/processors/simplified_parser_processor.class.php: call to restore_structure_parser_processor->postprocess_chunk()
  • line 92 of /backup/util/xml/parser/processors/progressive_parser_processor.class.php: call to simplified_parser_processor->process_chunk()
  • line 186 of /backup/util/xml/parser/progressive_parser.class.php: call to progressive_parser_processor->receive_chunk()
  • line 233 of /backup/util/xml/parser/progressive_parser.class.php: call to progressive_parser->publish()
  • line ? of unknownfile: call to progressive_parser->start_tag()
  • line 175 of /backup/util/xml/parser/progressive_parser.class.php: call to xml_parse()
  • line 154 of /backup/util/xml/parser/progressive_parser.class.php: call to progressive_parser->parse()
  • line 110 of /backup/util/plan/restore_structure_step.class.php: call to progressive_parser->process()
  • line 181 of /backup/util/plan/base_task.class.php: call to restore_structure_step->execute()
  • line 192 of /backup/moodle2/restore_activity_task.class.php: call to base_task->execute()
  • line 177 of /backup/util/plan/base_plan.class.php: call to restore_activity_task->execute()
  • line 167 of /backup/util/plan/restore_plan.class.php: call to base_plan->execute()
  • line 333 of /backup/controller/restore_controller.class.php: call to restore_plan->execute()
  • line 184 of /backup/util/ui/restore_ui.class.php: call to restore_controller->execute_plan()
  • line 99 of /backup/restore.php: call to restore_ui->execute()