Hello,
ich have a problem using cakephp.
I want to create tracking links, so at the beginning i have made
function, called mailer(). This function takes the id of the page and
increments the counter. The problem is that i always receive an error
message: "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 'updateAll' at line 1"
That's why i have tried with the method rawQuery(), with a working
query, but i still receive the error message.
Can somebody help me ?
function mailer($page_id = '') {
//$this->Nllink->updateAll(array('Nllink.counter' =>
'Nllink.counter
+ 1'), array('Nllink.page_id' => $page_id));
//$q = "UPDATE nllinks SET counter = '711' WHERE
nllinks.page_id = ".
$page_id;
//echo $q;
//$this->Nllink->rawQuery($q);
$this->Nllink->updateAll(array('counter' => '8'),
array('page_id' =>
$page_id));
$this->redirect('seminars/view/'.$page_id);
}
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---