在不改程序的情况下,修改 sql 时,需要将 Mapper 中的 XML 文件 放到外面
mybatis:
mapper-locations: classpath:mapper/*.xml #JAR 包里面
mybatis:
mapper-locations: file:mapper/*.xml # classpath 改成 path mapper和jar包同级目录的一个文件 存放xml配置文件,也可以是绝对路径
在不改程序的情况下,修改 sql 时,需要将 Mapper 中的 XML 文件 放到外面
mybatis:
mapper-locations: classpath:mapper/*.xml #JAR 包里面
mybatis:
mapper-locations: file:mapper/*.xml # classpath 改成 path mapper和jar包同级目录的一个文件 存放xml配置文件,也可以是绝对路径
本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。