[Solar-talk] Solar_Sql_Select bug

Jeff Moore jeff at mashery.com
Wed May 14 14:34:43 CDT 2008


Hi,

I found a small bug.  This code fails to detect an parenthesis in  
position 0.

Solar/Sql/Select.php:1043
                 $parens = strpos($col, '(');

                 // choose our column-name deconfliction strategy
                 if ($prefix == '' || $parens || $count_sources == 1) {

You could use

$parens = (strpos($col, '(') === FALSE);

To fix the bug

Best Regards,

Jeff


More information about the Solar-talk mailing list