secureswitools/swisistools/source/dbmanager/dbprocessor.cpp
changeset 33 8110bf1194d1
parent 0 ba25891c3a9e
child 50 c6e8afe0ba85
--- a/secureswitools/swisistools/source/dbmanager/dbprocessor.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/dbmanager/dbprocessor.cpp	Fri May 14 15:58:48 2010 +0300
@@ -376,6 +376,13 @@
 	CheckSqlErrCode(err);
 	}
 
+void CStatement::BindBinary(TInt aParameterIndex, const std::wstring &aParameterStr)
+	{
+	TInt err = iLibraryHandler.sqlite3_bind_blob(iStmtHandle, aParameterIndex, aParameterStr.c_str(), aParameterStr.size()*2, SQLITE_TRANSIENT);
+	// The fifth argument has the value SQLITE_TRANSIENT, it means that SQLite makes its own private copy of the data immediately
+	CheckSqlErrCode(err);
+	}
+
 void CStatement::Reset()
 	{
 	TInt err = iLibraryHandler.sqlite3_reset(iStmtHandle);