create table demo(text varchar2(2000))
Table created.
insert into demo values ('my email is john.smith@oracle.com')
1 row(s) inserted.
create index demoindex on demo(text) indextype is ctxsys.context
Index created.
select token_text from dr$demoindex$i
| TOKEN_TEXT | COM | JOHN | ORACLE | SMITH |
|---|
select * from demo where contains(text, 'john.smith') > 0
| TEXT | my email is john.smith@oracle.com |
|---|
drop index demoindex
Index dropped.
exec ctx_ddl.drop_preference('mylexer')
Statement processed.
exec ctx_ddl.create_preference('mylexer', 'BASIC_LEXER')
Statement processed.
exec ctx_ddl.set_attribute('mylexer', 'PRINTJOINS', '@.')
Statement processed.
create index demoindex on demo(text) indextype is ctxsys.context parameters ('lexer mylexer')
Index created.
select token_text from dr$demoindex$i
| TOKEN_TEXT | JOHN.SMITH@ORACLE.COM |
|---|
select * from demo where contains(text, 'john.smith') > 0
no data found
select * from demo where contains(text, 'john.smith@oracle.com') > 0
| TEXT | my email is john.smith@oracle.com |
|---|