日期:2014-05-16 浏览次数:20999 次
select t3.dep_id,t3.dep_name,t2.typename,t1.equipid,t1.equipname,t1.fixdate,t1.original from equip t1,type t2,dep t3 where t1.typeid=t2.typeid and t1.dep_id=t3.dep_id
create or replace view v_equip as --创建视图
select e.dep_id,
d.dep_name,
t.typename,
e.equipid,
e.equipname,
e.fixedate,
e.original
from equip e
left join dep d
on d.dep_id = e.dep_id
left join type t
on t.typeid = e.typeid