Mastering Oracle SQL学习笔记.pdfVIP

  1. 1、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。。
  2. 2、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  3. 3、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
  4. 4、该文档为VIP文档,如果想要下载,成为VIP会员后,下载免费。
  5. 5、成为VIP后,下载本文档将扣除1次下载权益。下载后,不支持退款、换文档。如有疑问请联系我们
  6. 6、成为VIP后,您将拥有八大权益,权益包括:VIP文档下载权益、阅读免打扰、文档格式转换、高级专利检索、专属身份标志、高级客服、多端互通、版权登记。
  7. 7、VIP文档为合作方或网友上传,每下载1次, 网站将根据用户上传文档的质量评分、类型等,对文档贡献者给予高额补贴、流量扶持。如果你也想贡献VIP文档。上传文档
查看更多
Mastering Oracle SQL学习笔记

Mastering Oracle SQL 学习笔记 一、第 2 章:Where子句 1 二、第 3 章:连接 2 三、第 4 章:分组操作: 9 四、第5 章:子查询(Subquery) 12 五、第 6 章:处理时间数据 20 六、第 7 章:集合运算(Set Operation): 30 七、第 8 章:Hierachical Querys(级联查询) 37 八、第 9 章 Decode和Case 45 九、第 13 章Advanced Analytic SQL(高级分析函数) : 50 十、第 14 章 SQL Best Practise(SQL最佳实践) : 55 一、第 2 章:Where 子句 *************************************************************************************** 1.Between…And 子句: When using BETWEEN, make sure the first value is the lowest of the two values provided. While BETWEEN 1 AND 10 and BETWEEN 10 AND 1 might seem logically equivalent, specifying the higher value first guarantees that your condition will always evaluate to FALSE 2.NULL 关键字: When working with NULL, the concept of equality does not apply; a column may be NULL, but it will never equal NULL. Oracle doesnt complain if you mistakenly use the equality operator when evaluating for NULL,The following query will parse and execute but will never return rows: SELECT order_nbr, cust_nbr, sale_price, order_dt FROM cust_order WHERE ship_dt = NULL; NVL substitutes a specified value for columns that are NULL, as in: SELECT fname, lname, manager_emp_id FROM employee WHERE NVL(manager_emp_id, -999) != 11; In this example, the value -999 is substituted for all NULL values, which, since -999 is never equal to 11, guarantees that all rows whose manager_emp_id column is NULL will be included in the result set. Thus, all employees whose manager_emp_id column is NULL or is not NULL and has a value other than 11 will be retrieved by the query. 3.如何充分利用 WHERE子句: here are a few tips to help you make the most of your WHERE clauses: A.Check your join conditions carefully. Make sure that each data set in the FROM clause is properly joined. Keep in mind that some joins require multiple conditions. See Chapter 3 for more information.

文档评论(0)

xcs88858 + 关注
实名认证
文档贡献者

该用户很懒,什么也没介绍

版权声明书
用户编号:8130065136000003

1亿VIP精品文档

相关文档