0
兩個領域我想比較移動或電子郵件字段存在於數據庫應該更新行其他插入行如何更新或插入比較來自數據庫
$ref = Ref::updateOrCreate(
[
'mobile' => $request['mobile'],
'email' => $request['email_address']
],
[
'firstname' => $request['firstname'],
"lastname" => $request['lastname'],
"mobile" => $request['mobile'],
"email" => $request['email_address'],
"mobile_verified" => $req->session()->get('mobile_verified'),
"quiz_data" => $req->session()->get('quiz_data'),
"verification_token" => $req_token
]
);
@Akki你試過這個嗎? –