引入外部属性文件.properties
之后出错
运行报错如下:
Exception encountered during context initialization - cancelling refresh attempt:> org.springframework.beans.factory.BeanInitializationException: Could not load properties; nested exception is java.io.FileNotFoundException: class path resource [classpath*:jdbc.properties] cannot be opened because it does not exist
仔细检查了一下代码,也没发现什么错误,于是就尝试着把在Spring的配置文件中修改了引入属性文件的表标签
修改前:
修改后: