Create PartTree against the domain type.

We now derive queries against the domain type and no longer using the result type to ensure query mapping and query creation against the domain type.

Closes #1688
This commit is contained in:
Mark Paluch
2023-12-05 15:07:40 +01:00
parent 7b6a239adf
commit 52fbdb05ce
3 changed files with 14 additions and 12 deletions

View File

@@ -107,7 +107,8 @@ public class PartTreeJdbcQuery extends AbstractJdbcQuery {
this.converter = converter;
this.rowMapperFactory = rowMapperFactory;
this.tree = new PartTree(queryMethod.getName(), queryMethod.getEntityInformation().getJavaType());
this.tree = new PartTree(queryMethod.getName(), queryMethod.getResultProcessor()
.getReturnedType().getDomainType());
JdbcQueryCreator.validate(this.tree, this.parameters, this.converter.getMappingContext());
}