From e9ecbccaa6547cb067653e7240947a76cc60d8ed Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Fri, 6 Jan 2017 02:11:57 +0000 Subject: Use SQL hash for prepared statement names, increases reuse and avoids random reuse --- libpqpp/pq-cursorselectcommand.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'libpqpp/pq-cursorselectcommand.cpp') diff --git a/libpqpp/pq-cursorselectcommand.cpp b/libpqpp/pq-cursorselectcommand.cpp index d130b89..d754680 100644 --- a/libpqpp/pq-cursorselectcommand.cpp +++ b/libpqpp/pq-cursorselectcommand.cpp @@ -7,10 +7,10 @@ AdHocFormatter(PQCursorSelectDeclare, "DECLARE %? CURSOR FOR "); AdHocFormatter(PQCursorSelectFetch, "FETCH %? IN %?"); AdHocFormatter(PQCursorSelectClose, "CLOSE %?"); -PQ::CursorSelectCommand::CursorSelectCommand(Connection * conn, const std::string & sql, unsigned int no, const PQ::CommandOptions * pqco) : +PQ::CursorSelectCommand::CursorSelectCommand(Connection * conn, const std::string & sql, const PQ::CommandOptions * pqco, const DB::CommandOptions * opts) : DB::Command(sql), PQ::SelectBase(sql), - PQ::Command(conn, sql, no), + PQ::Command(conn, sql, opts), executed(false), txOpened(false), fTuples(pqco ? pqco->fetchTuples : 35), -- cgit v1.2.3