SPR-7364: added separator property to database populator to deal with things like PL/SQL

This commit is contained in:
David Syer
2011-06-02 16:22:26 +00:00
parent ac735d73ac
commit 14edc9fc03
21 changed files with 288 additions and 72 deletions

View File

@@ -0,0 +1,2 @@
insert into T_TEST (NAME) values ('Keith')@@
insert into T_TEST (NAME) values ('Dave')@@

View File

@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:jdbc="http://www.springframework.org/schema/jdbc"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-3.1.xsd">
<jdbc:embedded-database id="dataSource" type="HSQL"/>
<jdbc:initialize-database data-source="dataSource">
<jdbc:script location="classpath:org/springframework/jdbc/config/db-schema.sql"/>
<jdbc:script location="classpath:org/springframework/jdbc/config/db-test-data-endings.sql" separator="@@"/>
</jdbc:initialize-database>
</beans>

View File

@@ -0,0 +1,2 @@
insert into T_TEST (NAME) values ('Keith')@@
insert into T_TEST (NAME) values ('Dave')@@

View File

@@ -0,0 +1,5 @@
insert into T_TEST (NAME)
values ('Keith')
insert into T_TEST (NAME)
values ('Dave')

View File

@@ -0,0 +1,2 @@
insert into T_TEST (NAME) values ('Keith');
insert into T_TEST (NAME) values ('Dave');

View File

@@ -0,0 +1,2 @@
insert into T_TEST (NAME) values ('Keith')
insert into T_TEST (NAME) values ('Dave')

View File

@@ -0,0 +1,5 @@
insert into T_TEST (NAME) values ('Keith')
/
insert into T_TEST (NAME) values ('Dave')
/