Attendance
Maintained by
Dan Marsden
A plugin that allows an attendance log to be kept. - includes an optional block for easy access to relevant functions.
Comments
Comments are no longer open for new posts. Existing comments remain available to read.
If that doesn't work and you are looking for development support you could ask for help in the forums or contract a developer or Moodle Partner to help further.
Debug info: Unknown column 'ats.studentscanmark' in 'field list'
SELECT CONCAT(?, ats.id), ats.id, ats.groupid, ats.sessdate, ats.duration, ats.description, al.statusid, al.remarks, ats.studentscanmark
FROM mdl_attendance_sessions ats
RIGHT JOIN mdl_attendance_log al
ON ats.id = al.sessionid AND al.studentid = ?
WHERE ats.attendanceid = ? AND ats.sessdate >= ?
ORDER BY ats.sessdate ASC
[array (
0 => 'c',
1 => 7804,
2 => '59',
3 => '1415088000',
)]
Error code: dmlreadexception
Stack trace: •line 441 of \lib\dml\moodle_database.php: dml_read_exception thrown
•line 996 of \lib\dml\mysqli_native_moodle_database.php: call to moodle_database->query_end()
•line 1341 of \mod\attendance\locallib.php: call to mysqli_native_moodle_database->get_records_sql()
•line 379 of \mod\attendance\renderables.php: call to attendance->get_user_filtered_sessions_log_extended()
•line 75 of \mod\attendance\view.php: call to attendance_user_data->__construct()
I noticed someone else had this probelm but I did not see their solution.
Please help
Click on the hyperlinked letters above (P,A,L,E) each column to select all.
Best,
O.
I want to do some change in the display of the list of students at time of taking attendance. Can you please guide me which file I require to edit.
What I speculate on my current situation is that I have a relatively newer version of the plug-in, but the old table structure in my database. Or am I completely wrong?
And if that's the case, is it possible to modify the database so that it works well again, without losing any data?
Thanks for replying back so promptly.
All right, my current version appears to be 2014022802 on the add-list, but I'm still getting the following update notice:
"There is a new version 2014022802 available! Release 2.6.2"
I tried installing the update through Moodle's interface, but it didn't proceed at all. Whenever I hit the install button, I find myself back on the notifications page without a summary page.
I manually downloaded 2.6.2 from the link as prompted and replaced it with the mod/attendance folder via FTP, still no progress.
Joseph, I have run the command on mysql and got this:
Field Type Null Key Default Extra
id bigint(10) NO PRI auto_increment
attendanceid bigint(10) NO MUL 0
groupid bigint(10) NO MUL 0
sessdate bigint(10) NO MUL 0
duration bigint(10) NO 0
lasttaken bigint(10) YES
lasttakenby bigint(10) NO 0
timemodified bigint(10) YES
description longtext NO
descriptionformat tinyint(2) NO 0
I'm not sure if "studentscanmark" should show up here as a field?
Dan, I guess my first upgrade attempt was over the GUI, and no customization have been made as far as I know.
By the way, I have got a clone of the same system and haven't upgraded the attendance module there. When I upload the older version of the "attendance" folder, the "report" function surprisingly works; however, I get this module version/content discrepancy error when I log in with an admin account.
I'd really appreciate any kind of workaround as I need to upgrade the current Moodle version to 2.7.2 soon.
Thanks in advance,
O.
Which version have you installed?
Can you run the following on your database (assuming it is mysql the command will differ for other dbs):
'describe mdl_attendance_sessions;'
This will list the field information for the table can you verify that 'studentscanmark' is there.
...
Joseph Baxter
University of Nottingham
I upgraded to the newest version a couple days ago, and now I keep getting this error:
Debug info: Unknown column 'ats.studentscanmark' in 'field list'
SELECT CONCAT(?, ats.id), ats.id, ats.groupid, ats.sessdate, ats.duration, ats.description, al.statusid, al.remarks, ats.studentscanmark
FROM mdl_attendance_sessions ats
RIGHT JOIN mdl_attendance_log al
ON ats.id = al.sessionid AND al.studentid = ?
WHERE ats.attendanceid = ? AND ats.sessdate >= ?
ORDER BY ats.sessdate ASC
[array (
0 => 'c',
1 => 2201,
2 => '380',
3 => '0',
)]
Error code: dmlreadexception
Stack trace:
line 443 of /lib/dml/moodle_database.php: dml_read_exception thrown
line 996 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()
line 1341 of /mod/attendance/locallib.php: call to mysqli_native_moodle_database->get_records_sql()
line 379 of /mod/attendance/renderables.php: call to attendance->get_user_filtered_sessions_log_extended()
line 75 of /mod/attendance/view.php: call to attendance_user_data->__construct()
Any suggestions on how to fix this?
Thanks a lot in advance,
--Ozan
I would like also to export the photography field to excel or other format.
It is possible?
Option 1 - If you don't need to keep existing attendance data or activities go to admin > plugins > activities and find the attforblock entry and hit the delete option - this will delete all existing attendance data - then you can install the new mod/attendance block.
Option 2:
* first delete the new mod/attendance files you have added to your site
* install the "newest" version of attforblock available via the 2nd link I posted above:
http://docs.moodle.org/27/en/Attendance_module#OLD_Branches
(the newest version there is for Moodle 2.4)
If this doesn't work - then you're on your own. This old plugin has never been tested on Moodle 2.7 - you should have upgraded the modattforblock plugin on your old 2.4 site before upgrading to Moodle 2.7 you could try option 1 above or get a developer to help you with this (I can't help with this as a volunteer sorry)
If upgrading the old attforblock plugin worked in your Moodle 2.7 you can then delete the mod/attforblock directory on your server and add the new mod/attendance code and run the upgrades.