ITPub博客

首页 > Linux操作系统 > Linux操作系统 > oracle10g 新特性 用q 引用特殊字符

oracle10g 新特性 用q 引用特殊字符

原创 Linux操作系统 作者:jetgm 时间:2019-02-10 13:06:05 0 删除 编辑

q and use

any convenient delimiter, single or multibyte, or any of the [ ], { }, ( ), or < >
character pairs.

select q'x's'dfsdfx' from dual;

select q'!'s'dfsdf!' from dual;

得到的结果是's'dfsdf

The new quote operator can also be used with the new SQL_TUNE function, which
takes a SQL statement as its argument. For example:
EXECUTE SQL_TUNE –
('select * from emp where name LIKE ''%DBMS_%''', ...)
With the new quote operator, you can rewrite this statement as:
EXECUTE SQL_TUNE –
(q'!select * from emp where name LIKE '%DBMS_%'!')


来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/6456/viewspace-112226/,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2002-02-06

  • 博文量
    44
  • 访问量
    35131