0
我有一個項目表,它包含了2場:PLEVEL1和PRINTOU3:Laravel更新領域,與其他字段值
我發送到更新功能百分比參數,我想更新PLEVEL1 WITH PRINTOUT3像這樣:
public function updatePrice($brandid, $itemgroup, $percentage){
$update=DB::table('sd_salesitems')->where('BRAND_ID', $brandid)
->where('SL_GROUP', $itemgroup)
->update(array('PLEVEL1' => 'PRINTOUT3'+'PRINTOUT3'*$percentage/100)); }
它更新到0,這是不正確的,任何想法?
工作,謝謝 –