有趣的sql(4) - 关于注释的,续"有趣的sql(1) "

1. 这个结果会是什么?

SELECT 2 --
-1 from dual;

提示:要是按照“有趣的sql(1)”的思路,有可能会犯错误的!

2. 这个有错吗?

select sysdate
REMARK from dual;

3. 这个呢?

create or replace
/* hello */
procedure hello
as
begin
null;
end;
/

4. 还有这些:

SELECT 'Y' FROM DUAL; -- Testing

select sysdate
-- comment;
from dual;

注:1.为自编。 2.3.4 摘自SQL*Plus User's Guide and Reference

Published At
Categories with 数据库类
Tagged with
comments powered by Disqus