Hi -

I am having a little trouble with the find function in a model.
When I use opening and closing parenthesis cake generates an invalid
query.

For example in my model I have -




$term = '(pasta)';
$cond = array("pizza" => $term);
$num  = $this->findCount($cond);

and returns the SQL slightly wonkey (invalid)

SELECT COUNT(*) AS count FROM food_table Food WHERE (pizza (pasta) '')






While this code

$term = 'pasta';
$cond = array("pizza" => $term);
$num  = $this->findCount($cond);

returns the SQL

SELECT COUNT(*) AS count FROM food_table Food WHERE (pizza = 'pasta')







Any idea what I need to do to have the find function parse this
correctly?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to