重庆思庄Oracle、Redhat认证学习论坛
标题: ORA-32766: instr with negative offset: use varchar semantics on LOBs [打印本页]
作者: michaeljet 时间: 2016-9-2 09:25
标题: ORA-32766: instr with negative offset: use varchar semantics on LOBs
Cause: The current varchar behavioris different. e.g. instr('abcd', 'cd', -2, 1)
returns 3, whereas instr(to_clob('abcd'), 'cd', -2, 1)returns 0, (i.e. no match),
because the reverse search starts from offset -2, whichpoints to 'c' and moving
backward, i.e. 'd' is ignored. This is symmetric toinstr('dcba','dc',2,1), which
returns 0.
Action: ORACLE uses the same varcharsemantics on LOBs (instr). Using the
same example, instr(to_clob('abcd'), 'cd', -2, 1) willreturn 3 as in the varchar case.
欢迎光临 重庆思庄Oracle、Redhat认证学习论坛 (http://bbs.cqsztech.com/) |
Powered by Discuz! X3.2 |