Friday, August 28, 2009

Problems with updateAll

Hi guys!!!

Could someone help me here please, this is urgent!!!

I getting crazy with this method. Look what I'm doing:
<?php
$this->Account->updateAll(
array('Account.memb__pwd' => 'qweqwe'),
array('Account.memb___id' => 'mylogin')
);
?>

and I'm getting this:
11 SELECT [Account].[memb_guid] AS [Account__0] FROM [MEMB_INFO] AS
[Account] WHERE [Account].[memb___id] = 'mylogin' 1 1 2

12 UPDATE [MEMB_INFO] SET [memb__pwd] = qweqwe WHERE [memb_guid] =
('1') Invalid column name 'qweqwe'. 337

I wanna update the field memb__pwd, but I dont wanna select id
(memb_guid) first and later update the field using that ID and I dont
wanna use query method.

How can I do that?

In a few words, what I want:
UPDATE [MEMB_INFO] SET [memb__pwd] = 'qweqwe' WHERE [Account].
[memb___id] = 'mylogin'

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments: