You are here: Re: MySql count « PHP Programming Language « IT news, forums, messages
Re: MySql count

Posted by Andy Hassall on 11/20/06 17:58

On Mon, 20 Nov 2006 18:48:39 +0100, Michael Fesser <netizen@gmx.de> wrote:

>.oO(Christoph Burschka)
>
>>Akhenaten wrote:
>>
>>> The following snippet (for whatever reason) returns no value for the
>>> count. Suggestions?
>>> [...]
>>
>>1. You can't pass variables within single quotes.
>>[...]
>>
>>2. Strings in MySQL queries need to be surrounded by quotes (either single or
>>double).
>>[...]
>
>3. mysql_query() just returns a resource ID. You have to use one of the
>mysql_fetch_* functions to get the actual results.

4. Always check for errors, as the database can tell you what went wrong via
mysql_error().

--
Andy Hassall :: andy@andyh.co.uk :: http://www.andyh.co.uk
http://www.andyhsoftware.co.uk/space :: disk and FTP usage analysis tool

 

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

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