Hi,
I am using a custom query on 1 of my models (an update query), so I
use $this->Model->query('update query here');
Does anyone know how to get a return value back, something like true
or false, I am asking because I want to set up commit and rollback
transactions on some queries, since I am doing a few updates on
different tables.
When I do:
if($this->Model->query('update query here'))
{
// persist the data
}
else
{
$this->model->rollback();
}
I never enter the first condition , and it always rolls back even
though my database fields are actually updating.
Any help is appreciated,
Thanks
Emmanuel
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---