Skip to content
This repository has been archived by the owner on Jan 29, 2020. It is now read-only.

View scheduled option results in dmlreadexception error #286

Open
ThomasITS opened this issue Sep 3, 2019 · 5 comments
Open

View scheduled option results in dmlreadexception error #286

ThomasITS opened this issue Sep 3, 2019 · 5 comments

Comments

@ThomasITS
Copy link

The View Scheduled option returns a dmlreadexception error. This was experienced in Moodle 3.7.1 and Quickmail v2.2.0. The full error and stack trace experienced should be:

stack_trace

@rrusso
Copy link
Contributor

rrusso commented Sep 3, 2019

I don't have access to MSSQL. What version of MSSQL are you running against? I will try and see if I can find a solution to this without just removing the sorts. It seems like MSSQL might want the same prefix (even though it's unique) for the sort column as used for the table.

It looks like it might be as simple as changing line 196 of blocks/quickmail/classes/repos/queued_repo.php

from ORDER BY ' . $sortby . ' ' . $sortdir;
to ORDER BY m.' . $sortby . ' ' . $sortdir;

@ThomasITS
Copy link
Author

Robert, thanks for the reply. It's MS SQL 2017 (14.0.3223.3).

@cperves
Copy link
Contributor

cperves commented Oct 1, 2019

Hello,
pull request #289 will solve your problem

@ThomasITS
Copy link
Author

We installed the branch including pull request #289, but we receive a different error when accessing the View Scheduled option. We are now running Moodle 3.7.2. The error is:
trace

@ThomasITS
Copy link
Author

Just an update to this issue, we experience the same error when choosing the Sent Message History option as well.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants