note 26806 added to ref.mysql
| From: | opaf at yahoo dot com | Date: | Wed, 13 Nov 2002 13:56:04 +0000 |
| Subject: | note 26806 added to ref.mysql | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-39447@lists.php.net to get a copy of this message | ||
Two notes about PHP and MySQL:
1. Get used to the syntax
$myquery = "<your query here>";
$result = mysql_query($myquery);
instead of
$result = mysql_query("<your query here>");
Some of the benefits of the proposed syntax are:
- abilty to perform a global search to your scripts nice and easy
- ability to easily output/debug your queries
2. The second note has more to do with MySQL:
Timestamp fields update automaticaly everytime you issue an Update query. Read the documentation!!
I lost 3 days of my life because of this
--
http://www.php.net/manual/en/ref.mysql.php
http://master.php.net/manage/user-notes.php?action=edit+26806
http://master.php.net/manage/user-notes.php?action=delete+26806
http://master.php.net/manage/user-notes.php?action=reject+26806