MyBatis There is no getter for property named 'xxx' in 'class java.lang.String'

1. Code

1.1 mapper xml


1.2 mapper interface
public interface OrderDao {
	public List getItems(String orderIds);
}

2. Issue

There is no getter for property named 'orderIds' in 'class java.lang.String'

3. Solution

import org.apache.ibatis.annotations.Param;

public interface OrderDao {
	public List getItems(@Param("orderIds") String orderIds);
}


Reference

[1] http://stackoverflow.com/questions/19848861/mybatis-dynamic-sql-using-longs

你可能感兴趣的:(J2EE)