Oracle ctxcat.context contains unusual exhibit behavior for specific search parameters

In Oracle Database 10g and Oracle Database Express Edition 11g, I came across some weird behavior. I have a column that is indexed as an index of type ctxsys.context. When I query a table for results using the contains function, it works, unless the value I'm looking for is "Still." Then it does not return any results. When I look for the same data with a column like "Still", I get the results as usual. If I search for "Jazz" using contains, I usually get results.

Below sql I used to reproduce this behavior in a newly created test pattern.

-- Setup the table with an index and some data
create table "STILL_TEST" (
    "ID" number(22,0) primary key,
    "PROF_DATA_15" varchar2(255 char),
    "OTHER" varchar2(255 char),
    "SHORTER" varchar2(100 char)
);
insert into "STILL_TEST" values (1, 'Still', 'Still', 'Still');
insert into "STILL_TEST" values (3, 'Jazz', 'Jazz', 'Jazz');
CREATE INDEX "STILL_TEST_PROF_DATA_15" ON "STILL_TEST" ("PROF_DATA_15")
   INDEXTYPE IS "CTXSYS"."CONTEXT" PARAMETERS ('SYNC (ON COMMIT)');
commit;

-- Now query it a bit. See how both types of queries work if the
-- parameter is 'Jazz'
select * from "STILL_TEST" where prof_data_15 like 'Jazz';
select * from "STILL_TEST" where contains(prof_data_15, 'Jazz') > 0;
select * from "STILL_TEST" where prof_data_15 like 'Still';
-- So far so good, but why doesn't this next query return any results?
select * from "STILL_TEST" where contains(prof_data_15, 'Still') > 0;
+5
1

, . -, "" .

:

 CREATE INDEX "STILL_TEST_PROF_DATA_15" ON "STILL_TEST" ("PROF_DATA_15")
 INDEXTYPE IS "CTXSYS"."CONTEXT" PARAMETERS ('STOPLIST CTXSYS.EMPTY_STOPLIST');

-:

http://docs.oracle.com/cd/A91202_01/901_doc/text.901/a90121/cdatadi9.htm

http://docs.oracle.com/cd/A91202_01/901_doc/text.901/a90121/astopsu2.htm#43324

, "" .

+4

All Articles