发布网友 发布时间:2022-05-01 04:46
共3个回答
懂视网 时间:2022-05-01 09:07
SELECT a.areaname as 二级地名 FROM houses h,houses h2,
areas a WHERE h.areaid=a.areasid AND h2.areaid=a.areasid AND h.finalassessmentid=1 AND
h.houseslevel=2 AND h2.houseslevel=1 AND a.areasid!=a.parentareasid AND a.companysid=2;
select * from areas
select count(h.houseslevel) as 总数,count(h1.houseslevel) as 最新累计成盘,count(h2.houseslevel) as 最新累计必交盘 from houses h,houses h1,houses h2 where h.houseslevel in (1,2) and h1.houseslevel=1 and h2.houseslevel=2;
select count(h.houseslevel) as 总数 from houses h where h.houseslevel in (1,2)
union all
select count(h.houseslevel) as 成盘 from houses h where h.houseslevel=1
union all
select count(h.houseslevel) as 成盘 from houses h where h.houseslevel=2;
select
count(h.houseslevel) as 总数,
count(case when h.houseslevel=1 then h.housesid end ) 成盘 ,
count(case when h.houseslevel=2 then h.housesid end ) 比较盘
from houses h,areas a where h.areaid=a.areasid and h.houseslevel in (1,2)
SELECT a.areaname AS 二级地名,
count(a.houseId) AS 最新累计有效待售数,
count(h.houseslevel) AS 最新累计必卖盘,count(h2.houseslevel) AS 最新累计成盘 FROM houses h,houses h2,
areas a WHERE h.areaid=a.areasid AND h2.areaid=a.areasid AND h.finalassessmentid=1 AND h.houseslevel=2 AND h2.houseslevel=1 AND a.areasid!=a.parentareasid AND a.companysid=2;
SELECT a.areaname AS 二级地名 FROM houses h,areas a WHERE h.areaid=a.areasid AND a.areasid!=a.parentareasid
SELECT a.areaname AS 二级地名 FROM areas a where a.areaname=
select a.areaname AS 二级地名 from areas a
where a.areaname in (select b.areaname from areas b group by b.areaname having count(b.areaname) > 1)
select b.areaname as 二级地名,count(b.areaname) as 重复数据量 from areas b group by b.areaname having count(b.areaname) > 1
select h.houseslevel from houses h where h.houseslevel=1;
select a.areaname AS 二级地名 from houses h,areas a where h.areaid=h.areaid and h.houseslevel=1 and a.areasid!=a.parentareasid AND a.companysid=2 and h.finalassessmentid=1;
select a.areaname AS 二级地名,
count(h.houseslevel) as 总数,
count(case when h.houseslevel=1 then h.housesid end ) 成盘 ,
count(case when h.houseslevel=2 then h.housesid end ) 比较盘
from houses h,areas a where h.areaid=a.areasid and h.houseslevel in (1,2) and a.areasid!=a.parentareasid AND a.companysid=2 and h.finalassessmentid=1 and flag1=1 group by a.areaname;
oracle的sql积累..&..decode函数使用
标签:
热心网友 时间:2022-05-01 06:15
是的。
一、理解数据库基本常识,sql语法,pl/sql语法及简单应用,oracle体系结构,oracle性能优化,掌握一个开发工具,掌握一些DBA管理知识,不断积累经验 。
二、oracle 先看最基础的东西,自己再装个oracle 9i或oracle 10g之类的,先登陆sql*plus
练习基本的建表,等DDL.DML.DCL语句操作。
三、Oracle是一个一个比较大的体系结构,随着Oracle公司的逐步发展,他的业务领域也在不段的扩张,进来Oracle公司更是先后收购bea,sun公司。
四、可以从Oracle的PL/SQL开始学习,PL/SQL是Oralce独立的SQL语言集,里面涉及到sql语言,oracle的PL/SQL包,调用,异常,游标等一系列知识。要进行这个学习,你必须要要了解到一些基础的数据库知识,sql基础知识等,通过这个学习,你如果能够比较好的掌握住PL/SQL知识的话,也不错,据我了解,国内一些比较大的保险,金融公司对这个是有一定需求量的。
五、从一些入门型的介绍开始,了解到大致的Oralce的内存结构,主要的进程部件,和存储管理。然后具体的去研究每个大项中对应在Oracle里表现。和性能优化这块了。
热心网友 时间:2022-05-01 07:33
能够学习过sql自然是最好,不过没学习过也无所谓,oracle也可以作为你的数据库语言开端。