is this correct ? UPDATE uhbedoccupancy SET occtodate = occfromdate , occtotime =…
- User
is this correct ?
UPDATE uh_bed_occupancy SET
occ_to_date=occ_from_date,occ_to_time=occ_from_time,occ_mod_date_time= NOW() WHERE occ_rid = 365442; - Assistant
Yes, the SQL update statement you provided syntactically appears to be correct assuming the goal is to update the entries in certain fields of the
uh_bed_occupancytable. Here is a breakdown and understanding of what your query does:-
Table: The updates are made on the
uh_bed_occupancytable. -
Fields Updated:
occ_to_dateis set to the current value ofocc_from_date.occ_to_timeis set to the current value ofocc_from_time.occ_mod_date_timeis set to the current date and time using theNOW()function, which returns the current date and time.
-