shell script:
if [ id > 0 ]
then
/usr/bin/mysql -uuser -p"$pass" database"$id" < database"$id".sql
echo $id
fi
done < $file
if I run it through terminal, everything works perfectly. But when I use php function shell_exec()
shell_exec("/home/g/user/shellfile.sh")
output is id variable (as expected), script executes too fast, and no changes in database. Why so?