Skip to content

Commit 0409166

Browse files
committed
Better error message when property not found.
1 parent d511320 commit 0409166

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/oatpp-postgresql/Executor.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,10 @@ Executor::QueryParams::QueryParams(const StringTemplate& queryTemplate,
9494
auto value = typeResolver->resolveObjectPropertyValue(it->second, queryParameter.propertyPath, cache);
9595
if(value.valueType->classId.id == oatpp::Void::Class::CLASS_ID.id) {
9696
throw std::runtime_error("[oatpp::postgresql::Executor::QueryParams::QueryParams()]: "
97-
"Error. Can't bind object property. Property not found or its type is unknown.");
97+
"Error."
98+
" Query '" + extra->templateName->std_str() +
99+
"', parameter '" + var.name->std_str() +
100+
"' - property not found or its type is unknown.");
98101
}
99102

100103
auto& data = outData[i];

0 commit comments

Comments
 (0)