Re: [PHP-DB] how to get ERROR message
Hi, dud you try to use something like this $result=mssql_query("exec x") or die(mssql_get_last_message()); instead of $result=mssql_query("exec x") or die("query failed"); Removing the "or die" part must display an error message too, but it won't end the script execution. Dobromir Velev -Original Message- From: jong jong <[EMAIL PROTECTED]> To: [EMAIL PROTECTED] <[EMAIL PROTECTED]> Date: Thursday, July 05, 2001 7:38 PM Subject: [PHP-DB] how to get ERROR message >Hi, > >How can I see the error message from browser? My code >is like this: > >$conn=mssql_connect("xxx","",""); >mssql_select_db("xxx",$conn); >$result=mssql_query("exec x") or die("query >failed"); >mssql_free_result($result); >?> > > >I got "query failed" on the browser screen and nothing >else. Here is some value I got from phpinfo(): > Configuration >PHP Core > Directive Local value Master value >display_errors On On >display_startup_errors > Off Off >doc_root no value no value >enable_dlOn On >error_append_string Off Off >error_log no value no value >error_prepend_string > OffOff >error_reporting 2039 2039 > >Are they enough to display the error messages? >Please help! I really do need to trace the errors. > >Thanks, >jongjong > >__ >Do You Yahoo!? >Get personalized email addresses from Yahoo! Mail >http://personal.mail.yahoo.com/ > >-- >PHP Database Mailing List (http://www.php.net/) >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] >To contact the list administrators, e-mail: [EMAIL PROTECTED] > > -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] how to get ERROR message
echo mysql_error(); Allen Lee http://MissoulaWeb.com $10/month PHP4 and MySQL hosting On Thu, 5 Jul 2001, jong jong wrote: > Hi, > > How can I see the error message from browser? My code > is like this: > > $conn=mssql_connect("xxx","",""); > mssql_select_db("xxx",$conn); > $result=mssql_query("exec x") or die("query > failed"); > mssql_free_result($result); > ?> > > > I got "query failed" on the browser screen and nothing > else. Here is some value I got from phpinfo(): > Configuration > PHP Core >Directive Local value Master value > display_errors On On > display_startup_errors > Off Off > doc_root no value no value > enable_dlOn On > error_append_string Off Off > error_log no value no value > error_prepend_string > OffOff > error_reporting 2039 2039 > > Are they enough to display the error messages? > Please help! I really do need to trace the errors. > > Thanks, > jongjong > > __ > Do You Yahoo!? > Get personalized email addresses from Yahoo! Mail > http://personal.mail.yahoo.com/ > > -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DB] how to get ERROR message
Hi, How can I see the error message from browser? My code is like this: I got "query failed" on the browser screen and nothing else. Here is some value I got from phpinfo(): Configuration PHP Core Directive Local value Master value display_errors On On display_startup_errors Off Off doc_root no value no value enable_dlOn On error_append_string Off Off error_log no value no value error_prepend_string OffOff error_reporting 2039 2039 Are they enough to display the error messages? Please help! I really do need to trace the errors. Thanks, jongjong __ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail http://personal.mail.yahoo.com/ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]