update pm storage

BEGIN
#Routine body goes here...
INSERT INTO EMS_PM_STORAGE (
AMOID,
GP_BEGIN_TIME,
EMS_RECORD_TIME,
ZDC_L_LODA
) SELECT
epl.AMOID,
epl.GP_BEGIN_TIME,
TIMESTAMPDIFF(
MINUTE,
epl.GP_BEGIN_TIME,
MAX(epl.LOG_TIME)
) - 15 RECORD_TIME2,
TIMESTAMPDIFF(
MINUTE,
epr.GP_BEGIN_TIME,
MAX(epr.RECORD_TIME)
) - 15 ZDC_L_LODA
FROM
EMS_PM_LOG epl,EMS_PM_REPORT epr
WHERE
epl.AMOID=epr.AMOID AND epl.GP_BEGIN_TIME=epr.GP_BEGIN_TIME
GROUP BY
epl.AMOID,
epr.GP_BEGIN_TIME; END
上一篇:ubuntu 终端无法启动:ImportError: cannot import name 'sysconfig' from 'distutils'


下一篇:C#设计模式——桥接模式(Bridge Pattern)