I am working on iris-for-money app: https://github.com/oliverwilms/iris-for-money
Account.csp posts a rest call with _SYSTEM username and the password.
xhttp.open("POST", "/restapi/sql/" + query, true,"_SYSTEM","SYS");
xhttp.send();
The error is logged in Riches.REST for this line:
Set tSC = tStatement.%Prepare(pQuery)