在用mybatis框架写项目时,配置数据库连接时直接从之前的项目中复制粘贴写好的配置语句,但是发现报一下错误:
The content of element type "configuration" must match
"(properties?,settings?,typeAliases?,typeHandlers?,objectFactory?,objectWrapperFactory?,reflectorFactory?,plugins?,environments?,databaseIdProvider?,mappers?)".
原因:mybatis-config.xml文件标签有严格的顺序要求得,不能随便乱写。
解决方案:按规定把写好的标签放到对应的位置。