[Solar-talk] Possible issue with Solar_Sql_Select::_addSource()
Travis Swicegood
development at domain51.com
Tue Dec 12 07:34:56 PST 2006
Howdy all,
Just ran into an issue with Solar_Sql_Select. I was doing as select
that had an IFNULL in it and I hit a funky error.
$result = $select->from('some_table', 'IFNULL(some_value, 0) AS
some_value')...
That would cause an unknown column error because it was trying to look
for a column named "some_table.0". The issue was that _addSource()
explodes on ','.
The work around is to cast your column as an array, but that seemed odd
to me. If that's the intended behavior I would at a minimum document it
or better I'd make _addSource() intelligent enough to not explode inside
parenthesis.
-Travis
More information about the solar-talk
mailing list