I must to implement command : java -jar test.jar page.xml | mysql -u user -p base in ant. So i Have tried with this task:
java -jar test.jar page.xml | mysql -u user -p base
There you are actually running a java command.
You need to use Exec task http://ant.apache.org/manual/Tasks/exec.html but not sure if there also you can run piped commands or not. Give it a try.