ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 10719] - Files processed under SQL task are hacked
Date Sat, 27 Jul 2002 15:17:09 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10719>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10719

Files processed under SQL task are hacked





------- Additional Comments From kdenehy@att.net  2002-07-27 15:17 -------
Thanks for the explanation, Jose.  I appreciate your intentions, but I still
think it should be the responsibility of the SQL script to be cross-platform, it
should *not* be Ant's responsibility.

If I'm developing a system that targets multiple databases, and I want to put
cross-platform comments in the script, can't I create an Ant property to do
this?  For example, can't I create a {sql.comment} property (and set it to "--"
for Oracle, or "//" for another platform, etc.), and then my script can read:

create or replace
stored procedure xyz is

{sql.comment} ************************************************
{sql.comment} *
{sql.comment} * This procedure does absolutly nothing
{sql.comment} *
{sql.comment} ************************************************
begin
    null; {sql.comment} do nothing
end; {sql.comment} End of procedure xyz

And after doing a usenet search on google, I found that the SQL92 standard
specifies "--" as the standard anyway (although we all know the commercial
vendors do a mediocre job of conforming to the standard), as shown in this snippet:

<simple comment> ::=
          <simple comment introducer> [ <comment character>... ] <newline>

<simple comment introducer> ::= <minus sign><minus sign>[<minus sign>...]

Of course I'm assuming that something I found in usenet is correct, which is a
bit of a gamble, but it looked legitimate.

So, IMHO, you should leave all comments (and formatting) alone, document the
fact that "--" is the official "cross-platform" SQL92 comment indicator (after
verifying that it _really_ is), and warn developers that not all databases are
100% SQL92 compliant, so "--" may not work.

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message