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 41836] - No warning from SQL task, but jdbc gets SQL State: 23000
Date Wed, 14 Mar 2007 22:22:20 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=41836>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=41836





------- Additional Comments From apache@digicoast.com  2007-03-14 15:22 -------
> it doesnt look for and print warnings.

I see.   Since Ant was displaying data truncate warnings as errors I was 
assuming it was already behaving as if there was a "failOnWarning".  But what 
appears to actually be happening is that MySQL jdbc Connector/J already 
escalates these types of MySQL warnings into JDBC errors.

When I add jdbcCompliantTruncation=false to the jdbc connection string (e.g., 
"jdbc:mysql://localhost/?jdbcCompliantTruncation=false)" and issue a statement 
that causes a MySQL Warning, I now get a warning in Java (versus an exception 
when jdbcCompliantTruncation=true), but Ant does not show the warning at all -- 
which is the behavior you described.

> 1. log the warnings at INFO or WARN
> 2. add a failOnWarning attribute to trigger behaviour on warnings
> Would this work?

Yes, those would solve the problem for me.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

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


Mime
View raw message