diff --git a/src/jrd/extds/ExtDS.cpp b/src/jrd/extds/ExtDS.cpp index 736260ea222..f6e11c58e1b 100644 --- a/src/jrd/extds/ExtDS.cpp +++ b/src/jrd/extds/ExtDS.cpp @@ -2235,6 +2235,12 @@ void Statement::setInParams(thread_db* tdbb, const MetaName* const* names, const FB_SIZE_T excCount = in_excess ? in_excess->getCount() : 0; const FB_SIZE_T sqlCount = m_sqlParamNames.getCount(); + if (m_error = (!names && sqlCount)) + { + // Parameter name expected + ERR_post(Arg::Gds(isc_eds_prm_name_expected)); + } + // OK : count - excCount <= sqlCount <= count // Check if all passed named parameters, not marked as excess, are present in query text