I want to set a date
field to NOW()
if it's outdated. Here is the query I'm trying to run without success:
DB::table('quizzes')->update('date', DB::raw('NOW()'))->where('date', '<', DB::raw('NOW()'))
How do I fix it?
P.S
I don't want to deal with Carbon
, if possible, to avoid the server/DB time difference issues.
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire