oracle instr有关问题
来源:互联网 发布:阿里云订单退款 编辑:程序博客网 时间:2024/05/17 08:11
oracle instr问题
...
and instr(personcode,'33') > 0
查询对应personcode字段中含33的所有记录,
1.
我现在想使得'33'为该personcode字段的开头部分,该怎么写instr
2.
例:personcode : 38330021
'33'如果为第三个字符开始,第四个字符结束,又该如何写instr
------解决方案--------------------------------------------------------
------解决方案--------------------------------------------------------
1. instr(personcode,'33',1,1) =1 表示以33开头,从第一个位置开始找,找到1个匹配项
2.instr(personcode,'33',3,1)=3 表示从第三个位置开始找,找到1个匹配项,返回位置是3的。
------解决方案--------------------------------------------------------
INSTR(C1,C2,I,J) 在一个字符串中搜索指定的字符,返回发现指定的字符的位置;
C1 被搜索的字符串
C2 希望搜索的字符串
I 搜索的开始位置,默认为1
J 出现的位置,默认为1
SQL> select instr( 'oracle traning ', 'ra ',1,2) instring from dual;
...
and instr(personcode,'33') > 0
查询对应personcode字段中含33的所有记录,
1.
我现在想使得'33'为该personcode字段的开头部分,该怎么写instr
2.
例:personcode : 38330021
'33'如果为第三个字符开始,第四个字符结束,又该如何写instr
------解决方案--------------------------------------------------------
------解决方案--------------------------------------------------------
1. instr(personcode,'33',1,1) =1 表示以33开头,从第一个位置开始找,找到1个匹配项
2.instr(personcode,'33',3,1)=3 表示从第三个位置开始找,找到1个匹配项,返回位置是3的。
------解决方案--------------------------------------------------------
INSTR(C1,C2,I,J) 在一个字符串中搜索指定的字符,返回发现指定的字符的位置;
C1 被搜索的字符串
C2 希望搜索的字符串
I 搜索的开始位置,默认为1
J 出现的位置,默认为1
SQL> select instr( 'oracle traning ', 'ra ',1,2) instring from dual;
本文固定链接:http://www.verydemo.com/demo_c158_i14886.html
0 0
- oracle instr有关问题
- 有关instr函数的问题
- ORACLE下 instr函数使用问题!
- oracle instr
- ORACLE INSTR()
- oracle instr
- oracle instr
- oracle instr()
- oracle instr
- oracle instr应用,解决where in排序问题
- oracle instr() ltrim() rtrim()
- oracle INSTR方法
- Oracle instr函数
- oracle中instr函数
- 【转】Oracle INSTR用法
- ORACLE INSTR用法
- Oracle的instr函数
- oracle dbms_lob.instr
- oracle体系结构详解
- 进击IT
- Java通过Jolt调用Tuxedo服务
- python里的str.translate的用法
- Python 去除list中重复的元素
- oracle instr有关问题
- Hadoop海量视频、图像分析分布式处理总结
- Spring security 命名空间的使用
- 设计模式七大原则
- javascript学习-2 - Javascript教程
- OpenCV+VS2010+JavaCV+Eclipse+Win7
- android 无线调试
- JavaDES加密解密算法
- hdu-1800 Flying to the Mars