【问题标题】:Storing static table data as a collection in myBatis在 myBatis 中将静态表数据存储为集合
【发布时间】:2013-11-04 21:06:47
【问题描述】:

我在我的ORM框架中使用myBatis。我需要将静态表(例如国家表)的数据加载到内存中,并能够在其他业务对象需要时使用。有没有有效的方法来执行这在 myBatis 中?

【问题讨论】:

  • 你看过mybatis缓存吗?

标签: select mybatis static-data


【解决方案1】:

您需要在映射中添加<cache/> 元素。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2013-11-09
    • 1970-01-01
    • 1970-01-01
    • 2016-03-31
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多