The most typical reason for "working in the shell, but not in cron" is that the commands you are trying to execute are not in PATH .. The reason is that the shell called by cron aint loads the same files as your shell entrance.
Fix: add an absolute path to each command that you are trying to execute.
The second thing that I notice on your team. The syntax for running your date command does not seem very portable. Change this to be in backticks, or run the entire command in shellscript (also you can use it to set your path too) and run this script from cron ..
EDIT:
At the time of writing my original answer, my keyboard layout did not have backticks, so check what Pascal wrote.
And an example of what you could do with shellscript:
Copy the following command to /usr/local/bin/dumptable.sh
#!/bin/sh /usr/bin/mysqldump --host=HOST --user=USER --password=PASSWORD DATABASE TABLE | /bin/gzip > /tmp/table.`/bin/date +"\%Y-\%m-\%d"`.gz
and then put /usr/local/bin/dumptable.sh in cron ..
rasjani
source share