title: Ant couldn't connect to mysql (access denied), but mysql client could
body: <p>I hava the next task in my ant file:</p>
  
  <pre><code>&lt;target name="initdb"&gt;  
    &lt;sql driver="com.mysql.jdbc.Driver"
         url="jdbc:mysql://localhost:3306/dtest"
         userid="root" password="oksaoksaoksa" &gt;
      &lt;classpath&gt;
        &lt;pathelement path="./lib/mysql-connector-java-5.1.13-bin.jar"/&gt;      
      &lt;/classpath&gt;
      &lt;transaction  src="./init.sql"/&gt;
    &lt;/sql&gt;
  &lt;/target&gt;
  </code></pre>
  
  <p>When I run it, I see the error:</p>
  
  <pre><code>BUILD FAILED
  /home/sbos/projects/texterra-tests/deploy.xml:43: java.sql.SQLException: Access denied for user 'root'@'localhost' (using password: YES)
  </code></pre>
  
  <p>However, I can login with such login and password with mysql client:</p>
  
  <pre><code>mysql -u root -p
  Enter password: &lt;oksaoksaoksa&gt;
  Welcome to the MySQL monitor.  Commands end with ; or \g.
  ...
  </code></pre>
  
  <p>Why this happens? I've just installed mysql in ubuntu 10.10 if that matters</p>