update方法好.sql
来自「地方政府非税收入管理程序。powerbulider8开发。」· SQL 代码 · 共 29 行
SQL
29 行
/*UPDATE titles
SET ytd_sales = titles.ytd_sales + sales.qty
FROM titles, sales
WHERE titles.title_id = sales.title_id
AND sales.ord_date = (SELECT MAX(sales.ord_date) FROM sales)
UPDATE titles
SET ytd_sales =
(SELECT SUM(qty)
FROM sales
WHERE sales.title_id = titles.title_id
AND sales.ord_date IN (SELECT MAX(ord_date) FROM sales))
FROM titles, sales
*/
update t_print1 set lj_month=null,lj_year=null
update t_print1
set lj_month = (select sum(money) from t_mx
where t_print1.dwdm=t_mx.dwdm and t_print1.sfdm=t_mx.sfdm and t_mx.IN_Time>='20060601')
from t_print1,t_mx
update t_print1
set lj_year = (select sum(money) from t_mx
where t_print1.dwdm=t_mx.dwdm and t_print1.sfdm=t_mx.sfdm)
from t_print1,t_mx
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?