Re: Sybase Query- Problems with Pound Sign

From: Date: Wed, 06 Aug 2003 02:41:07 +0000
Subject: Re: Sybase Query- Problems with Pound Sign
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-29710@lists.php.net to get a copy of this message
Jeremy Peterson wrote:
I am having a problem with a query that has a pound sign in it. The results are quite puzzling, it seems like the page doesn't load if the query is present. I have tested this on other tables without the pound sign and they work beautifully, seems like the pound sign is the troublemaker to me. [snip]
$sql = "select * from item where bib# = 300";
The # character is generally used to start comments, so everything after it is ignored in your query. I'm surprised you could even name a column like that... -- ---John Holmes... Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/ PHP|Architect: A magazine for PHP Professionals – www.phparch.com

« previous php.db (#29710) next »