随笔分类 -  oracle

个人关于oracle学习的一些记录
摘要:昨天工作过程中发现一个奇怪的地方: 代码段A: 1 select * from table1 2 order by no 3 union all 4 select * from table2 运行代码段1,在第三步显示命令未正确结束。我自然很困惑,问了前辈才知道原来问题出在order by上。 修改 阅读全文
posted @ 2016-12-29 09:37 努力的小叶子 阅读(5448) 评论(0) 推荐(0)
摘要:trunc取得是天(可比较),而to_char取得是数值(可计算): 但trunc(date) 具有与to_char(date) 相似的功能,但有区别: trunc(sysdate,'cc') 取当世纪的第一天 to_char(sysdate,'cc') 取当世纪数值 trunc(sysdate,' 阅读全文
posted @ 2016-11-28 11:34 努力的小叶子 阅读(1971) 评论(0) 推荐(0)