Page 1 of 1

No longer allowed to send sql directly.

Posted: Mon Jan 30, 2023 3:36 am
by pid_user
In the middleTier mode- 22.3 we are unable to perform crud operation over database.
when i try to use other means like using
PrefCrud.Update
or PrefCrud.Insert it throws following error-
No longer allowed to send sql directly. Rewrite the calling class to not use this query.

Re: No longer allowed to send sql directly.

Posted: Mon Jan 30, 2023 9:45 am
by jsalmon
The purpose of Middle Tier (MT) is to run all queries on the MT server. CRUD methods do not have code present that will cause the MT server to run the query for them. You need to use a method that has the code present to pass the query along to the MT server. E.g. Prefs.UpdateInt(), Prefs.UpdateBool(), etc.