Issue in running shell script in crontab

I'm having a shell script which has to be run only once at the specified time.

Shell script is like following,
#!/bin/bash
db2 connect to XXX > connection_status.txt

This script is scheduled in crontab as following,

50 4 8 5 0 sh script.sh

scheduled script is run at the specified time and the connection_status.txt also created. But the file doesn't contain any content and file size is 0 byte.

Note: When I'm running the script as usual (without scheduling), Script runs fine and creates the connection_status.txt file with appropriate content.

Please help to know the reason why the scheduled script doesn't produce the expected result.

Thanks,
Rajkumar

Please check our FAQ before posting!