From 9134d603584241135be03ce2e9f2f66a46c44fc6 Mon Sep 17 00:00:00 2001 From: Constantin Michael Date: Tue, 5 Jul 2011 14:12:09 +0200 Subject: Aesthetic changes --- odb/pgsql/query.cxx | 8 ++++---- odb/pgsql/query.hxx | 4 ++++ odb/pgsql/statement.hxx | 7 +------ 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/odb/pgsql/query.cxx b/odb/pgsql/query.cxx index 5bf1f52..36a624b 100644 --- a/odb/pgsql/query.cxx +++ b/odb/pgsql/query.cxx @@ -149,7 +149,7 @@ namespace odb // Copy any remaining characters in q.clause_. // - if (cur_pos < q.clause_.length ()) + if (cur_pos < q.clause_.size ()) { size_t n (clause_.size ()); @@ -159,7 +159,7 @@ namespace odb clause_.append (q.clause_, cur_pos, string::npos); } - size_t n = bind_.size (); + size_t n (bind_.size ()); parameters_.insert ( parameters_.end (), q.parameters_.begin (), q.parameters_.end ()); @@ -212,13 +212,13 @@ namespace odb clause_ += ' '; parameter_offset o; - o.first = clause_.length (); + o.first = clause_.size (); ostringstream ss; ss << parameters_.size () + 1; clause_ += '$' + ss.str (); - o.second = clause_.length (); + o.second = clause_.size (); parameter_offsets_.push_back (o); parameters_.push_back (p); diff --git a/odb/pgsql/query.hxx b/odb/pgsql/query.hxx index 1d34545..933ecd9 100644 --- a/odb/pgsql/query.hxx +++ b/odb/pgsql/query.hxx @@ -1527,6 +1527,10 @@ namespace odb { bool dummy; std::size_t size, cap (buffer_.capacity ()); + + // NOTE: Using a fixed size bit type in queries requires + // alternative image buffer type support. + // value_traits::set_image (buffer_, size, dummy, v); size_ = size; diff --git a/odb/pgsql/statement.hxx b/odb/pgsql/statement.hxx index 09779b4..e248b07 100644 --- a/odb/pgsql/statement.hxx +++ b/odb/pgsql/statement.hxx @@ -39,8 +39,7 @@ namespace odb // Adapt an ODB binding to a native PostgreSQL parameter binding. // static void - bind_param (native_binding&, - const binding&); + bind_param (native_binding&, const binding&); // Populate an ODB binding given a PostgreSQL result. If the truncated // argument is true, then only truncated columns are extracted. Return @@ -141,10 +140,6 @@ namespace odb // splits fetch() into next() and load(). // public: - // Return false if there is no more rows. You should call next() - // until it returns false or, alternatively, call free_result (). - // Otherwise the statement will remain unfinished. - // bool next (); -- cgit v1.1