From 4af2971bac6d6214301f1b6002e27db071d9590b Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 15 Jul 2015 18:43:03 +0200 Subject: Implement SQLite incremental BLOB/TEXT I/O --- odb/mssql/statement-processing.cxx | 9 +++++---- odb/mssql/statement.cxx | 18 +++++++++--------- odb/mssql/statement.hxx | 6 +++--- 3 files changed, 17 insertions(+), 16 deletions(-) diff --git a/odb/mssql/statement-processing.cxx b/odb/mssql/statement-processing.cxx index e28e75c..a43851a 100644 --- a/odb/mssql/statement-processing.cxx +++ b/odb/mssql/statement-processing.cxx @@ -21,15 +21,16 @@ namespace odb typedef bind bind_type; void statement:: - process_select (const char* s, + process_select (std::string& r, + const char* s, const bind_type* bind, std::size_t bind_size, #ifndef LIBODB_DEBUG_STATEMENT_PROCESSING - bool optimize, + bool optimize #else - bool, + bool #endif - std::string& r) + ) { // This implementation is pretty much the same as the generic one // except for two things: diff --git a/odb/mssql/statement.cxx b/odb/mssql/statement.cxx index b74acaa..a25f21a 100644 --- a/odb/mssql/statement.cxx +++ b/odb/mssql/statement.cxx @@ -185,22 +185,22 @@ namespace odb switch (sk) { case statement_select: - process_select (text_, + process_select (text_copy_, + text_, proc->bind, proc->count, - optimize, - text_copy_); + optimize); break; case statement_insert: - process_insert (text_, + process_insert (text_copy_, + text_, &proc->bind->buffer, proc->count, sizeof (bind), - '?', - text_copy_); + '?'); break; case statement_update: - process_update (text_, + process_update (text_copy_, + text_, &proc->bind->buffer, proc->count, sizeof (bind), - '?', - text_copy_); + '?'); break; case statement_delete: assert (false); diff --git a/odb/mssql/statement.hxx b/odb/mssql/statement.hxx index 516ce7b..6837abd 100644 --- a/odb/mssql/statement.hxx +++ b/odb/mssql/statement.hxx @@ -89,11 +89,11 @@ namespace odb // columns to the end. // static void - process_select (const char* statement, + process_select (std::string& result, + const char* statement, const bind*, std::size_t bind_size, - bool optimize, - std::string& result); + bool optimize); protected: void -- cgit v1.1