pgsql 更新A表的x字段通过查询b表的z字段
查询表t_local_warning_hit_source的send_time 更新到表t_local_warning_source
WITH t2 AS ( SELECT ID, send_time FROM t_local_warning_hit_source WHERE send_time >= '2023-09-27 00:00:00' AND send_time < '2023-11-28 00:00:00' )
UPDATE t_local_warning_source ts
SET send_time = t2.send_time
FROM
t2
WHERE
ts.hit_source_id = t2.ID