diff --git a/include/sqlpp11/postgresql/bind_result.h b/include/sqlpp11/postgresql/bind_result.h index 6f655b44..ba13be47 100644 --- a/include/sqlpp11/postgresql/bind_result.h +++ b/include/sqlpp11/postgresql/bind_result.h @@ -38,7 +38,7 @@ #include "detail/prepared_statement_handle.h" -#if defined(_WIN32) || defined(_WIN64) +#ifdef _MSC_VER #pragma warning(disable : 4800) // int to bool #endif namespace sqlpp diff --git a/include/sqlpp11/postgresql/result.h b/include/sqlpp11/postgresql/result.h index 28a8a374..d985ce3c 100644 --- a/include/sqlpp11/postgresql/result.h +++ b/include/sqlpp11/postgresql/result.h @@ -33,6 +33,7 @@ #include #include +#include #include #include @@ -299,8 +300,15 @@ namespace sqlpp case PGRES_FATAL_ERROR: Err = PQresultErrorMessage(m_result); break; +#if PG_MAJORVERSION_NUM >= 13 case PGRES_COPY_BOTH: case PGRES_SINGLE_TUPLE: +#endif +#if PG_MAJORVERSION_NUM >= 14 + case PGRES_PIPELINE_SYNC: + case PGRES_PIPELINE_ABORTED: +#endif + default: throw sqlpp::exception("pqxx::result: Unrecognized response code " + std::to_string(PQresultStatus(m_result))); }