You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Solomon <so...@madigans.org> on 2010/05/12 08:47:19 UTC
SQL task
I am having a difficulty with the SQL task trying to send functions to the
mysql server. No mater what I have tried I get the error message that the
server could not execute 'CREATE FUNCTION...
My sql task is
...
<sql
driver="com.mysql.jdbc.Driver"
url="jdbc:mysql://192.168.1.30:3306/sommelier"
userid="xxx"
password="yyy"
autocommit="true"
delimitertype='normal' >
<fileset dir="../${project}/${project}">
<include name="${module}.sql"/>
</fileset>
</sql>
...
The Function is
CREATE FUNCTION isFoo ( paK INT, viK INT )
RETURNS BOOLEAN
READS SQL DATA
BEGIN
DECLARE fK INT;
SELECT fooK INTO fK
FROM Foo
WHERE pK = paK
AND vK = viK;
IF vK IS NULL THEN
RETURN false;
ELSE
RETURN true;
END IF;
END;
I have tried adding the DELIMITER ;; line in the end it has no effect. Any
guidance would be appreciated.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org