Something Interseting about Xojo SQLite Insert

Over all the use of prepared statements is the suggested way to go, and I get that.

Recently I went to add this functionality to my SWIFT Framework, where I’m replicating (subclassing, wrapping etc) functions to match Xojo syntax to make my own IDE system more flexible.

Now in Xojo API1 you needed to use BIND statements and Prepare statments and in API2 the need for BIND was removed.

Ironicially (prior to me even looking at how API2 did it), I tried to create Swift functions to duplicate the BIND syntax, and couldn’t, as there was no comparable way to implment it… Swift (or more precisely SQLite itself) already directly supported syntax similar to API2.

So my question is, since I doubt that was something “recent” to the SQLite Framework, why did the concept of BIND ever need to exist in API1 to begin with?

X-Database API?

API v2 and Swift are probably just preparing statements & parameter binding behind the scenes.

For DB’s other than SQLIte (postgresql, mssql, mysql etc) more than likely as that syntax existed way back when