catfan / Medoo

The lightweight PHP database framework to accelerate the development.
https://medoo.in
MIT License
4.83k stars 1.15k forks source link

In update copy field #1068

Closed louishot closed 8 months ago

louishot commented 1 year ago

Information

Describe the Problem A clear and concise description of what the problem is.

Detail Code The detail code you are using causes the problem.

// Write your PHP code here

Most of the features are like insert(), they support array serialization and type auto-detection. Additionally you can use [+], [-], [*] and [/] for mathematical operation.

Expected output A clear and concise description of what output you expected. users table Schema id,username,password,c_date,b_date

I need a SQL like this update users set c_date=b_date; I can't find description on how to do this in the docs.

I tried both doesn't work "c_date" => "b_date", "c_date[=]" => "b_date",

louishot commented 1 year ago

I did this it's works well for me "c_date" => Medoo::raw('b_date')