Bind by position or placeholder name?
I am creating statement wrapper class for C++Builder (C++98), which calls Poco functionality from modern C++ VS DLL. So I need to build the statement by calling different functions from the DLL like CreateStatement, BindInt, etc.. (can't use STL, because of the memory boundaries and different run-times).
Is it possible to bind values to a statement using specific position? The only way that I see right now is binding values in a proper order one after another:
Statement stmt = ( session << "INSERT INTO FORENAME VALUES(?, ?, ?)" );
stmt.addBind(bind(first_value));
stmt.addBind(bind(second_value));
stmt.addBind(bind(third_value));
What I need for my use case is to be able to bind by position:
Statement stmt = ( session << "INSERT INTO FORENAME VALUES(?, ?, ?)" );
stmt.addBind(bind(2, second_value));
stmt.addBind(bind(1, first_value));
stmt.addBind(bind(3, third_value));
Or by name:
Statement stmt = ( session << "INSERT INTO FORENAME VALUES(:first, :second, :third)" );
stmt.addBind(bind(":second", second_value));
stmt.addBind(bind(":first", first_value));
stmt.addBind(bind(":third", third_value));
Is this possible in Poco or is it something that is not yet supported?
This issue is stale because it has been open for 365 days with no activity.
This issue was closed because it has been inactive for 60 days since being marked as stale.