2 Replies Latest reply: Apr 27, 2012 5:31 AM by sperkmandl RSS

    CTX_QUERY.BROWSE_WORDS wrong case

    sperkmandl
      Hi, I'm browsing index word where the index was defined as mixed_case.
      Only one document was entered as test case: the Oracle Text app. dev. guide.
      Also I used the table solution, from jdbc.
      Seed word was "A", requesting always 10 terms.
      Straight table browsing ($i) reports around the "A" position:

      93
      94065
      97
      99
      996633
      A
      AAADXnAABAAAS3SAAC
      AAAPoEAABAAAMWsAAC
      AAAPoEAABAAAMWsAAG
      AAAPoEAABAAAMWsAAK
      AAAPoEAABAAAMWsAAO
      AAAPoEAABAAAMWsAAS
      ABOUT
      ABS
      ACCESS
      ACCUM
      ADD

      BROWSE_WORDS reports:

      AFTER:

      A
      ä
      aaa
      AAADXnAABAAAS3SAAC
      AAAPoEAABAAAMWsAAC
      AAAPoEAABAAAMWsAAG
      AAAPoEAABAAAMWsAAK
      AAAPoEAABAAAMWsAAO
      AAAPoEAABAAAMWsAAS
      abbreviations

      AROUND:

      ä
      aaa
      AAADXnAABAAAS3SAAC
      AAAPoEAABAAAMWsAAC
      AAAPoEAABAAAMWsAAG
      93
      94065
      97
      99
      996633

      It seems that this procedure fetches terms always in a case-insensitive way, in spite of index definition.
      I'm also a bit confused by getting terms sorted as case-insensitive, although Oracle order-by clause should be case-sensitive by default.
      I used a temp. table such as:

      CREATE GLOBAL TEMPORARY TABLE BROWSE (
           BROWSE_ID NUMBER,
           WORD VARCHAR2(64),
           DOC_COUNT NUMBER
           ) ON COMMIT PRESERVE ROWS;

      fetching as SELECT DOC_COUNT,WORD FROM BROWSE ORDER BY WORD ASC;

      Thanks for any suggestion.