Consider the following: If you w

2022-05-18  本文已影响0人  编程人生

今天在写项目时遇见下面一个错误,记录下:

Description:

Failed to configure a DataSource: 'url' attribute is not specified and no embedded datasource could be configured.

//无法配置数据库,没有指定url属性,并且无法配置embedded datasource

Reason: Failed to determine a suitable driver class

//原因:无法明确指定正确的驱动类(driver.class

Consider the following: If you want an embedded database (H2, HSQL or Derby), please put it on the classpath. If you have database settings to be loaded from a particular profile you may need to activate it (no profiles are currently active).

找了半天发现:mybatis xml中输入参数类型写错了,如下:

总结:

    如果项目之前没问题, 新增文件及修改xml 报这个错, 多半是由于xml 新增内容有误,检查新增内容即可.

上一篇 下一篇

猜你喜欢

热点阅读