提交 0c6d2341 编写于 作者: C Calvin

#127 支持sql中包含中文,设置编码

上级 f41b6042
...@@ -669,7 +669,7 @@ ...@@ -669,7 +669,7 @@
<target> <target>
<property file="src/main/resources/application.development.properties" /> <property file="src/main/resources/application.development.properties" />
<property file="src/main/resources/application.properties" /> <property file="src/main/resources/application.properties" />
<sql driver="${jdbc.driver}" url="${jdbc.url}" userid="${jdbc.username}" password="${jdbc.password}" onerror="continue"> <sql driver="${jdbc.driver}" url="${jdbc.url}" userid="${jdbc.username}" password="${jdbc.password}" onerror="continue" encoding="${project.build.sourceEncoding}">
<classpath refid="maven.test.classpath" /> <classpath refid="maven.test.classpath" />
<transaction src="src/main/resources/sql/h2/schema.sql"/> <transaction src="src/main/resources/sql/h2/schema.sql"/>
<transaction src="src/test/resources/data/import-data.sql"/> <transaction src="src/test/resources/data/import-data.sql"/>
......
...@@ -125,8 +125,8 @@ ...@@ -125,8 +125,8 @@
<!-- 嵌入式内存中数据库 --> <!-- 嵌入式内存中数据库 -->
<jdbc:embedded-database id="dataSource" type="H2"> <jdbc:embedded-database id="dataSource" type="H2">
<jdbc:script location="classpath:sql/h2/schema.sql" /> <jdbc:script location="classpath:sql/h2/schema.sql" />
<jdbc:script location="classpath:data/import-data.sql" /> <jdbc:script location="classpath:data/import-data.sql" encoding="UTF-8"/>
</jdbc:embedded-database> </jdbc:embedded-database>
</beans> </beans>
</beans> </beans>
\ No newline at end of file
...@@ -527,12 +527,12 @@ ...@@ -527,12 +527,12 @@
<target> <target>
<property file="src/main/resources/application.development.properties" /> <property file="src/main/resources/application.development.properties" />
<property file="src/main/resources/application.properties" /> <property file="src/main/resources/application.properties" />
<sql driver="${jdbc.driver}" url="${jdbc.url}" userid="${jdbc.username}" password="${jdbc.password}" onerror="continue"> <sql driver="${jdbc.driver}" url="${jdbc.url}" userid="${jdbc.username}" password="${jdbc.password}" onerror="continue" encoding="${project.build.sourceEncoding}">
<classpath refid="maven.test.classpath" /> <classpath refid="maven.test.classpath" />
<transaction src="src/main/resources/sql/h2/schema.sql"/> <transaction src="src/main/resources/sql/h2/schema.sql"/>
<transaction src="src/test/resources/data/import-data.sql"/> <transaction src="src/test/resources/data/import-data.sql"/>
</sql> </sql>
<sql driver="${quartz.jdbc.driver}" url="${quartz.jdbc.url}" userid="${quartz.jdbc.username}" password="${quartz.jdbc.password}" <sql driver="${quartz.jdbc.driver}" url="${quartz.jdbc.url}" userid="${quartz.jdbc.username}" password="${quartz.jdbc.password}" encoding="${project.build.sourceEncoding}"
src="src/main/resources/sql/h2/quartz.sql" onerror="continue"> src="src/main/resources/sql/h2/quartz.sql" onerror="continue">
<classpath refid="maven.test.classpath" /> <classpath refid="maven.test.classpath" />
</sql> </sql>
......
...@@ -134,7 +134,7 @@ ...@@ -134,7 +134,7 @@
<!-- 嵌入式内存中数据库 --> <!-- 嵌入式内存中数据库 -->
<jdbc:embedded-database id="dataSource" type="H2"> <jdbc:embedded-database id="dataSource" type="H2">
<jdbc:script location="classpath:sql/h2/schema.sql" /> <jdbc:script location="classpath:sql/h2/schema.sql" />
<jdbc:script location="classpath:data/import-data.sql" /> <jdbc:script location="classpath:data/import-data.sql" encoding="UTF-8" />
</jdbc:embedded-database> </jdbc:embedded-database>
<jdbc:embedded-database id="quartzDataSource" type="H2"> <jdbc:embedded-database id="quartzDataSource" type="H2">
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册