您的位置:首页 > 数据库 > Oracle

Oracle大文本查询 汉字按拼音排序

2011-12-21 16:44 253 查看
创建Oracle Text 文本索引:
CREATE INDEX doc_index ON docs(text) INDEXTYPE IS CTXSYS.CONTEXT

查询文本:

select a.content_id, a.content_name, a.content, a.type_id
from (select t.content_id,
t.content_name,
t.content,
t.type_id,
rownum - 1 numNo
from CONTENT_BAIKE t
where 1 = 1
and CONTAINS(t.key_word, '新疆') > 0
and t.type_id = 25000000) a
where a.numNo >= 0
and a.numNo < 10
order  by nlssort(a.content_name,'NLS_SORT=SCHINESE_PINYIN_M');


 

 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  oracle