I am getting the SQL error below but its not showing me the actual SQL
statement that Cake is generating. Is there any way of seeing what it is?
Warning (512): 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 'updateOrder' at line 1
[CORE/cake/libs/model/datasources/dbo_source.php.
My controller line is:
$this->Special->updateOrder($this->data));
which is calling the updateOrder in my model, which is:
function updateOrder($data){
$flag = true;
foreach ($data['Special'] as $key=>$value):
$this->id = $key;
if(!$this->saveField('order', $value['order'])):
$flag = false;
endif;
endforeach;
return $flag;
}
My data looks like:
Array
(
[Special] => Array
(
[1] => Array
(
[order] => 0
)
[4] => Array
(
[order] => 1
)
)
)
--
View this message in context:
http://old.nabble.com/How-do-I-see-a-SQL-statement--tp27217643p27217643.html
Sent from the CakePHP mailing list archive at Nabble.com.
Check out the new CakePHP Questions site http://cakeqs.org and help others with
their CakePHP related questions.
You received this message because you are subscribed to the Google Groups
"CakePHP" 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