Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.7.0

Bug #11463 int and string is a valid token after SELECT
Submitted: 2007-06-28 09:32 UTC
From: cybot Assigned: cybot
Status: Closed Package: SQL_Parser (version CVS)
PHP Version: 5.2.3 OS:
Roadmaps: 0.5.1    
Subscription  


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 13 + 2 = ?

 
 [2007-06-28 09:32 UTC] cybot (Sebastian Mendel)
Description: ------------ SELECT 1; or SELECT a; are valid SELECT expressions Test script: --------------- echo SELECT 1 FROM a; > test.sql php generate_testcases.php test.sql Expected result: ---------------- <?php $tests = array( array( 'sql' => 'SELECT 1 FROM a', 'expect' => array( 'command' => 'select', 'column_values' => array( 0 => 1 ), 'column_names' => array( 0 => 1 ), 'column_tables' => array( 0 => '' ), 'column_aliases' => array( 0 => '' ), 'table_names' => array( 0 => 'a' ), 'table_aliases' => array( 0 => '' ), 'table_join_clause' => array( 0 => '' ) ) ), ); ?> Actual result: -------------- <?php $tests = array( array( 'sql' => 'SELECT 1 FROM a', 'expect' => 'Parse error: Expected columns or a set function on line 1 SELECT 1 FROM a ^ found: "1"' ), ); ?>

Comments

 [2007-07-13 13:46 UTC] cybot (Sebastian Mendel)
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.