From 225b2fdd892ba7b1ba3c4d5ce73d59bd97ac8004 Mon Sep 17 00:00:00 2001 From: randomdan Date: Thu, 16 Sep 2010 18:55:42 +0000 Subject: Always rebind after a column alloc size change else ODBC doesn't know about the extra space --- libodbcpp/column.cpp | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) (limited to 'libodbcpp') diff --git a/libodbcpp/column.cpp b/libodbcpp/column.cpp index 9ed6143..828b4bc 100644 --- a/libodbcpp/column.cpp +++ b/libodbcpp/column.cpp @@ -28,15 +28,12 @@ ODBC::Column::resize(SQLHANDLE hStmt) void ODBC::CharArrayColumn::resize(SQLHANDLE hStmt) { - const char * addr = &data.front(); if (bindLen > SQLLEN(data.size())) { data.resize(bindLen + 1); - if (addr != &data.front()) { - Column::bind(); - if (paramCmd) { - paramBound = false; - Param::bind(); - } + Column::bind(); + if (paramCmd) { + paramBound = false; + Param::bind(); } } } -- cgit v1.2.3