No longer allowed to send sql directly.

This forum is for programmers who have questions about the source code.
Post Reply
pid_user
Posts: 67
Joined: Thu Jun 04, 2015 9:31 am

No longer allowed to send sql directly.

Post by pid_user » Mon Jan 30, 2023 3:36 am

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.

User avatar
jsalmon
Posts: 1551
Joined: Tue Nov 30, 2010 12:33 pm
Contact:

Re: No longer allowed to send sql directly.

Post by jsalmon » Mon Jan 30, 2023 9:45 am

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.
The best thing about a boolean is even if you are wrong, you are only off by a bit.

Jason Salmon
Open Dental Software
http://www.opendental.com

Post Reply