From:             dillama at canada dot com
Operating system: Linux
PHP version:      5.2.6
PHP Bug Type:     MySQL related
Bug description:  /* or -- no longer used as comment chars

Description:
------------
/* can no longer be used as a comment character to ignore all text after
this character (seems to only affect 5.2)

-- never worked as a comment character in previous version of PHP

Reproduce code:
---------------
$dbh = @mysql_connect ("localhost", "aaa", "aaa") or die ("Cannot connect
to DB");
mysql_select_db("test",$dbh) or die ("Cannot select DB");
$sql="select something from table /* dsfadsfasdfadfasdfasfdmkkn";

$result=mysql_query($sql,$dbh) or die ("Cannot submit query" .
mysql_error());


Expected result:
----------------
As similar to PHP 5.1 series, the above statement should run without
error. Note, -- should work but have never worked either.

Actual result:
--------------
SQL Error : 1064 You have an error in your SQL syntax; check the manual
that corresponds to your MySQL server version for the right syntax to use
near

-- 
Edit bug report at http://bugs.php.net/?id=45154&edit=1
-- 
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=45154&r=trysnapshot52
Try a CVS snapshot (PHP 5.3): 
http://bugs.php.net/fix.php?id=45154&r=trysnapshot53
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=45154&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=45154&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=45154&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=45154&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=45154&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=45154&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=45154&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=45154&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=45154&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=45154&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=45154&r=globals
PHP 4 support discontinued:   http://bugs.php.net/fix.php?id=45154&r=php4
Daylight Savings:             http://bugs.php.net/fix.php?id=45154&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=45154&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=45154&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=45154&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=45154&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=45154&r=mysqlcfg

Reply via email to