alanl1 Posted June 28, 2013 Share Posted June 28, 2013 Hi AllI have a php exec command which runs SQLCMD as follows the sqlcmd command works great by itself but when i run it in php it hangs, any ideas exec('c:\WINDOWS\system32\cmd.exe /c START C:\inetpub\wwwroot\batchfiles\export.bat'); this runs a sqlcmd batch file as follows sqlcmd -S d3licsql02 -d TestData -U sa -P sqldba -Q "select * from dbo.newtable" -s "," -o "C:\inetpub\wwwroot\cleansed\result.csv" Link to comment https://forums.phpfreaks.com/topic/279647-php-exec-command-hanging/ Share on other sites More sharing options...
trq Posted June 28, 2013 Share Posted June 28, 2013 It will hang until the process has completed. Link to comment https://forums.phpfreaks.com/topic/279647-php-exec-command-hanging/#findComment-1438314 Share on other sites More sharing options...
alanl1 Posted June 28, 2013 Author Share Posted June 28, 2013 but it takes less than half a second to run when i run it by itself, when it is in the php exec command it just hangs and hangs until an error is produced HTTP Error 500.0 - Internal Server Error C:\PHP 5\php-cgi.exe - The FastCGI process exceeded configured request timeout Link to comment https://forums.phpfreaks.com/topic/279647-php-exec-command-hanging/#findComment-1438316 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.