数据库sql编程题目,正在笔试求帮助
select xm 姓名,xb 性别,csrq 出生日期 from E;
select xm 姓名,round((sysdate-csrq)/365,0) 年龄 from e where xb='male';
select * from d where lx='技术服务中心';
select a.*,b.bmmc from (select dno,avg(money) jiangjin from r group by dno) a left join (select bmmc,dno from d group by bmmc,dno) b on a.dno=b.dno order by a.jiangjin desc
update r set money=money-100 where money>=600
update r set money=(1+0.5)*money where dno in (select dno from d where bmmc='项目三部')
delete from d where dno not in (select dno from r)
select a.eno,a.xm,b.bmmc,c.money from e a,d b,r c where a.eno=c.eno and a.dno=c.dno
select a.*,b.bmmc from (select dno from r where eno not in (select eno from e where xm='张三三')) a left join d b on a.dno=b.dno
最后一个自己写吧 哈哈
感谢感谢 太谢谢你了
select xm as 姓名,datediff(‘y',csrq,getdate()) from E where xb=N'男'
select * from d where lx=N'技术服务中心'
select dno,average(money) from r group by dno order by average(money) desc;
select money-100 as money,xm from e,r where e.eno=r.eno and money>600;
谢谢你了
还能写下面的吗