Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/349.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java Mybatis无法将多个列从主查询传递到关联查询_Java_Mybatis_Spring Mybatis - Fatal编程技术网

Java Mybatis无法将多个列从主查询传递到关联查询

Java Mybatis无法将多个列从主查询传递到关联查询,java,mybatis,spring-mybatis,Java,Mybatis,Spring Mybatis,将多个列从主查询传递到关联查询不起作用 org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.binding.BindingException: Parameter 'CustomerId' not found. Available parameters are [] @SelectProvider(type = CustomerProvider.class, method = "fe

将多个列从主查询传递到关联查询不起作用

org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.binding.BindingException: Parameter 'CustomerId' not found. Available parameters are []


@SelectProvider(type = CustomerProvider.class, method = "fetchAllById")
@Results({
        @Result(property="accounts",
                column="customerId, accountId",
                javaType=Account.class,
                one = @One(select="com.deeshank.dao.AccountMapper.fetchAccounts",
                        fetchType = FetchType.EAGER))
})
List<Customer> fetchAllById(CustomerQueryRequest queryRequest);
customerId和accountId来自主查询的select列。
非常感谢您的帮助。

使用mybatis 3.4.1版或更高版本解决了此问题