[
http://jira.codehaus.org/browse/MSQL-56?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Johan Romme updated MSQL-56:
----------------------------
Attachment: msql-56-include.diff
Include file patch.
Most database platforms have some tools to read and execute text files
containing sql and other platform specific syntax. Some of these platforms
support some form of 'include file' syntax. The patch file contains code to add
'include file' syntax to sql-maven-plugin for a few frequently used databases.
For this functionality one parameter is added to sql-maven-plugin:
enableIncludes=true/false that signals to use include file syntax or not. When
enableIncludes is set to true using a database platform for which currently no
include file support is available an IllegalArgumentException is thrown.
Include file support is added for oracle, ingres, mysql, derby and sql-server
(the last one is for now untested as I 'unfortunately' don't have access to a
sql-server test database). Adding support for other database platforms is easy,
per database platform 2 regular expressions handle all functionality.
> Plugin compatibility with SQLPlus
> ---------------------------------
>
> Key: MSQL-56
> URL: http://jira.codehaus.org/browse/MSQL-56
> Project: Maven 2.x SQL Plugin
> Issue Type: New Feature
> Affects Versions: 1.4
> Environment: Oracle 10
> Reporter: Nick Sayer
> Priority: Minor
> Attachments: msql-56-include.diff
>
>
> We'd like to use the same schema script files operationally to deploy our
> app(s) and for developers to develop with them.
> The issue is that operations uses sqlplus to run the scripts and we'd like
> for the developers to be able to use the sql plugin.
> The problems are twofold (that we've found so far):
> @ include file syntax
> PL/SQL block syntax
> An example of the latter is
> create table bar(insert_ts timestamp not null);
> create or replace trigger foo
> before insert on bar
> for each row
> begin
> select systime into :new.insert_ts FROM DUAL;
> end;
> /
> Note that the create table operation uses ; as the separator / terminator,
> but the trigger uses a / on a line by itself.
> If we use delimitor / and delimitorType row, then the file needs to be
> create table bar(insert_ts timestamp not null)
> /
> create or replace.......
> which, I believe, won't work with sqlplus.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email