First reported by Luis de Vasconcelos in http://moodle.org/mod/forum/discuss.php?d=114294:
Notice: The data types ntext and nvarchar are incompatible in the equal to operator.
INSERT INTO mdl_backup_ids (backup_code, table_name, old_id, info) SELECT '1232364873', 'question', q.id, '' FROM mdl_question q, mdl_backup_ids bk WHERE q.category = bk.old_id AND bk.table_name = 'question_categories' AND bk.info = 'course' AND bk.backup_code = '1232364873'
line 103 of lib\dmllib.php: call to debugging()
line 461 of question\backuplib.php: call to execute_sql()
line 445 of question\backuplib.php: call to question_insert_q_ids()
line 49 of mod\quiz\backuplib.php: call to question_insert_c_and_q_ids_for_course()
line 501 of mod\quiz\backuplib.php: call to quiz_insert_category_and_question_ids()
line 179 of in C:\Moodle\lib\weblib.php on line 6923
When I created the backup I selected just the following options on the backup screen (\backup\backup.php):
User Files: No
Course files: Yes
Site files used in this course: Yes
Grade histories: No
I don't want, and am not including, any user data in the backup.
Both instances of Moodle are on the same server and are running Moodle 1.9.3+ Build 20081112 (2007101531)
Is there a solution to the above error so that I can restore the Courses with all the quiz questions?
I had a look at the moodle.xml file in the course backup file and it does not contain any of the quiz questions.
Also, I was able to export the questions from MoodleDev1 to a GIFT file and then import the GIFT file into the quiz on MoodleDev2, but that isn't the ideal solution. Is there a way to get around the above data types error?
Windows Server 2003 SP2 Std Edition
IIS 6 (6.0.3790.3959)
PHP 5.2.6 (Non Thread Safe)
FastCGI from Microsoft
FreeTDS 18.104.22.168 (the NTS version built by Trevor Johnson,
MS SQL Server 2005 SP2 Std Edition (9.00.1399.00)
Certificate - Site Wide Report (080513)