2
我有一個主表格Cliente。該表與另外20個表相關聯。我正嘗試使用下面的代碼只更新表Clientee:只更新表格,但表格與另一個表格關聯
$this->Cliente->updateAll(array("ec_cnpj" => $this->request->data['Cliente']['ec_cnpj'],
"ec_cpf" => $this->request->data['Cliente']['ec_cpf'],
"ec_rg" => $this->request->data['Cliente']['ec_rg'],
"ec_rg_org_emissor" => $this->request->data['Cliente']['ec_rg'],
"ec_rg_est_emissor" => $this->request->data['Cliente']['ec_rg_est_emissor'],
"ec_nire" => $this->request->data['Cliente']['ec_nire']),
array("ec_codigo"=>$this->request->data['ec_codigo']))
不過,蛋糕是生成查詢更新所有表。我怎麼做只更新客戶表?
非常感謝您的幫助。工作得很好! – Stark 2013-05-17 17:25:10
謝謝你的回答,你能不能更新最後的[鏈接](http://bakery.cakephp.org/articles/cornernote/2006/12/10/unbindall),好像已經死了 – 2017-01-06 14:50:55
謝謝你了@Ayaou , 更新 :) – Nunser 2017-01-10 19:33:48