You are here: How to debug PHP's mysql_query() function? « PHP Programming Language « IT news, forums, messages
How to debug PHP's mysql_query() function?

Posted by John Moore on 11/02/05 20:39

Hi

I posted three days ago about a function I wrote which kept refusing
to run a mysql_query.

Well I did away with the function, and hard coded the variables into
the query itself. Here's what I have now:

mysql_query("UPDATE about SET category_id = 58 WHERE about_id = 5") or
die('error: ' . mysql_error());

Just running mysql_query, with no logic, I still dont get an update,
and the script doesn't die. What other things should I be looking at?

Here's another variation of the same thing I've tried:

mysql_query("UPDATE about SET category_id=60 WHERE about_id=5") or
trigger_error("SQL", E_USER_ERROR);

I've also done: $update = mysql_query("Blah blah blah"); and testing
$update gives me nothing. No errors, no update.

Thanks,

J Moore

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация