假设有如下表table:
id | str ---|--- 1 | B 1 | A
sql:
select id, str from table order by str;
显然会返回:
id | str ---|--- 1 | A 1 | B
考虑如下mybatis mapper:
属性id为1,属性strs类型为List,它的值一定会是["A","B"]吗?
List
["A","B"]
列表(List)与结果集的顺序一致。