select o.customer_id as 厂家编号 , f.factoryname as 厂家名称,o.file_id as 文件编号,
o.file_type as 文件类型,x.file_name as 文件名称,o.file_number as 文件内数量,o.finish_number as 处理完成数量
,(case when o.temp_flag=0 then ‘未入临时表’ when o.temp_flag=1 then '已经入临时表’end) as 临时表状态,
(case when o.process_result=0 then '未处理’end) as 处理状态 ,o.create_date as 加入日期,o.file_name as 文件名称
from 表1 o
left join 表2 f
on o.customer_id = f.factoryid
left join t_pdm_dic_filetype x
on o.file_type=x.file_type
where o.create_date >trunc(sysdate)-3 and o.process_result='0’and temp_flag=‘1’ order by o.create_date asc;
oracle数据统计1
最新推荐文章于 2021-04-04 00:23:21 发布