This Week in Starcounter – 16/06/2017June 16, 2017 12:38 pm Leave your thoughts
We’ve made two changes to the public API’s this week that are available from the Release Candidate version released tonight.
RunWithinApplication were in some cases used to query the database classes of other apps. Since
RunWithingApplication is now obsolete, we have introduced a new way to accomplish this –
Since it’s able to query all database classes, the full namespace of the classes have to be provided. For example:
string query = "SELECT p FROM MyApp.MyNamespace.MyClass p WHERE p.Property = ?"; var result = Db.GlobalSQL(query, "john")
DELETE is moved to
DELETE statement used to only be available from
Db.SlowSQL due to a limitation with large transactions. This limitation no longer exists, so it’s now also available in
Db.SQL. There’s no difference in functionality or performance between
DELETE in the two methods.
Db.SQL are identical except that
Db.SlowSQL supports literals which will never be added to
Db.SQL because of their inherently poor performance.
Db.SlowSQL should never have to be used in application code anymore.
Categorised in: Development, This Week in Starcounter
This post was written by Erlend Landrö