java - Ant build failed for mysql -


when run ant build using mysql following error occur

 cannot run program "mysql" (in directory   "d:\projects\obsworkspace\schoolforms\db"):       createprocess error=2, system cannot find file specified 

when run mysql in local cmd following message occur

error 1045 (28000): access denied user 'odbc'@'localhost' (using password:  no) 

how run ant generating , creating database script.

first of need try connect mysql via cmd line, example int way mysql -u root -p root know able it. secondly can ant build using code:

<project name="mysql.test" default="mysqltest">      <target name="mysqltest">         <exec executable="cmd.exe">             <arg value="mysql" />             <arg value="-u root" />             <arg value="-p root" />         </exec>     </target>  </project> 

you try not via cmd , thats why can't connect.


Comments

Popular posts from this blog

asp.net mvc 3 - Using mvc3, I need to add a username/password to the sql connection string at runtime -

kineticjs - draw multiple lines and delete individual line -

thumbnails - jQuery image rotate on hover -