select
w.workflowid,
w.requestid,
w.requestname,
w.requestmark,
CONVERT(char(11),w.createdate,120)+CONVERT(char(12),w.createtime,114) as 'createdate',
h.lastname,
c.groupid,
t.typename,
n.nodename,
CONVERT(char(11),c.receivedate,120)+CONVERT(char(12),c.receivetime,114) as 'receivedate',
CONVERT(char(11),c.operatedate,120)+CONVERT(char(12),c.operatetime,114) as 'operatedate',
CAST(CAST(DATEDIFF(ss, receivedate, CONVERT(char(11),c.operatedate,120)+CONVERT(char(12),c.operatetime,114)) / (60*60*24) AS INT) AS VARCHAR) + '天'
CAST(CAST(DATEDIFF(ss, CONVERT(char(11),c.receivedate,120)+CONVERT(char(12),c.receivetime,114), CONVERT(char(11),c.operatedate,120)+CONVERT(char(12),c.operatetime,114)) % 86400 / 3600 AS INT) AS VARCHAR) + '小时'
CAST(CAST(DATEDIFF(ss, CONVERT(char(11),c.receivedate,120)+CONVERT(char(12),c.receivetime,114), CONVERT(char(11),c.operatedate,120)+CONVERT(char(12),c.operatetime,114)) % 3600 / 60 AS INT) AS VARCHAR) + '分'
CAST(CAST(DATEDIFF(ss, CONVERT(char(11),c.receivedate,120)+CONVERT(char(12),c.receivetime,114), CONVERT(char(11),c.operatedate,120)+CONVERT(char(12),c.operatetime,114)) % 60 AS INT) AS VARCHAR) + '秒' AS 'SpendTime'
from workflow_requestbase w
inner join workflow_currentoperator c
on w.requestid=c.requestid
inner join hrmresource h
inner join workflow_nodebase n
inner join workflow_type t
and w.workflowid in
(select wfversionid from workflow_versionInfo where wfid=573)
-- and w.requestid=606859
-- order by groupid
ECOLOGY9.0查询流程经过节点的详细信息
kaka_19942023-10-06 23:25
相关推荐
程序员黑豆4 小时前
Java 注释详解:单行、多行与文档注释的完整指南hey_sml5 小时前
JAVA每日一学---CompletableFuture中thenApply与thenCompose区别详解Doraemomo5 小时前
数据结构-环形链表萧瑟余晖7 小时前
Java深入解析篇十七之SpringCloudIvorySQL7 小时前
PostgreSQL 日报 | JOIN 与外键优化(8 月 9 日)是未才7 小时前
从输入 URL 到页面返回:DNS、路由、TLS 与 HTTP 完整链路ltl7 小时前
自治数据库十年回顾:Peloton、NoisePage、OtterTune 到云原生 auto-tuningttod_qzstudio7 小时前
Java 常用语法极简通关(五):类与对象——字段、方法、构造器、this 与 static萧瑟余晖9 小时前
Java深入解析篇十七之Spring Security灯澜忆梦9 小时前
【MySQL10】进阶篇 | 索引_#2性能优化