Creating intermedia text index error

Hello. I tried creating an index using the below command
create index mydocs_text_index on
mydocs(thefile) indextype is ctxsys.context;
However, I received some error message as follows:
ERROR at line 1:
ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
ORA-20000: file not found
DRG-50704: file not found
ORA-28575: unable to open RPC connection to external procedure agent
ORA-06512: at "CTXSYS.DRUE", line 126
ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 54
ORA-06512: at line 1
What do you think is wrong?
Thank you

Is the listener up and running?
Installation
1.What are the steps to install interMedia Text manually, AFTER installing the code via the
installer?
A.
cd $ORACLE_HOME/ctx/admin
B. as SYS:
@dr0csys.sql ctxsys system temp
where ctxsys is the ctxsys password
system is the default tablespace for ctxsys
temp is the temporary tablespace for ctxsys
C. as CTXSYS:
@dr0inst.sql
/oracle/db/dev118/ctx/lib/libctxx8.so
(on Solaris)
where /oracle/db/dev118 is $ORACLE_HOME
D. as CTXSYS:
@defaults/drdefus.sql
Note: this is assuming you want U.S. to be your language default, otherwise run the
corresponding drdef for your language.
2.What are the steps to install interMedia Text manually, with a Net8 Configuration?
A. Configure an IPC listener address.
For example, change:
LISTENER =
(ADDRESS_LIST=
(ADDRESS=
(PROTOCOL=tcp) (HOST=ap118sun.us.oracle.com) (PORT=1521)
to:
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC) (KEY = EXTPROC0))
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP) (HOST = ap118sun) (PORT
=1521))
This shows the full LISTENER definition in your listener.ora. Note: EXTPROC0 ends in a
zero.
B. Add a system identifier (SID) name of PLSExtProc and a program name of EXTPROC in the server's LISTENER.ORA file.
For example, in the SID_LIST_LISTENER definition, insert:
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC = ...
(SID_DESC =
(SID_NAME=PLSExtProc)(ORACLE_HOME=/oracle/db/dev118)
(PROGRAM=extproc)
C. Add a net service name description entry for EXTPROC0 in the server's tnsnames.ora
file, using SID rather than SERVICE_NAME in the CONNECT_DATA section.
For example, add this to the end of tnsnames.ora:
extproc_connection_data =
(DESCRIPTION=
(ADDRESS_LIST =
(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC0))
(CONNECT_DATA=
(SID=PLSExtProc)
(PRESENTATION = RO)
This entry should be added exactly as you see it here (do NOT substitute your SID
anywhere, do NOT change the case of any text). Note: EXTPROC0 ends in a zero, RO
ends in an Oh
1.How do I check my interMedia Text installation and setup?
A.
lsnrct1status
should give you the following:
LSNRCTL for Solaris: Version
8.1.5.0.0 - Production on 31-MAR-99 18:57:49
(c) Copyright 1998 Oracle Corporation. All rights reserved.
Connecting to
(DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC0)))
STATUS of the LISTENER
Alias LISTENER
Version TNSLSNR for Solaris: Version 8.1.5.0.0 - Production
Start Date 30-MAR-99 15:53:06
Uptime 1 days 3 hr. 4 min. 42 sec
Trace Level off
Security OFF
SNMP OFF
Listener Parameter File
/private7/oracle/oracle_home/network/admin/listener.ora
Listener Log File
/private7/oracle/oracle_home/network/log/listener.log
Services Summary...
PLSExtProc has 1 service handler(s)
oco815 has 3 service handler(s)
The command completed successfully
The important information to understand here is the service handler for PLSExtProc.
B. Create a user/table/index/query thus:
As SYS or SYSTEM:
create user ctxtest identified by ctxtest ;
grant connect, resource, ctxapp to ctxtest ;
Do any other grants, quotas, tablespace etc. for the new user. As CTXTEST:
create table quick
quick_id number primary key,
text varchar(80)
insert into quick ( quick_id, text )
values ( 1, 'The cat sat on the mat' );
insert into quick ( quick_id, text )
values ( 2, 'The quick brown fox jumped over the lazy dog' );
commit;
create index quick_text on quick ( text )
indextype is ctxsys.context;
At this point, if your Net8 setup is NOT correct you will get:
create index quick_text on quick ( text )
ERROR at line 1:
ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
ORA-20000: ConText error:
DRG-50704: Net8 listener is not running or cannot start external procedures
ORA-28575: unable to open RPC connection to external procedure agent
ORA-06512: at "CTXSYS.DRUE", line 122
ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 34
ORA-06512: at line 1
If everything is OK, you will get:
Index created.
Now try some queries:
SQL> select quick_id from quick where contains(text, 'cat')>0;
QUICK_ID
1
SQL> select quick_id from quick where contains(text, 'fox')>0;
QUICK_ID
2
Congratulations !! You now have a successful interMedia Text V8.1 installation.
null

Similar Messages

  • InterMedia Text indexing error - can't open files

    I am getting the following error on 3 of 4 files for which I am trying to set up a simple text index:
    DRG-11101: failed to open file \drgit3
    Here are the steps/cmds I followed:
    begin
    ctx_ddl.create_preference('tracker_file_datastore','FILE_DATASTORE');
    ctx_ddl.set_attribute('tracker_file_datastore','PATH','d:\temp\pptd\doc');
    end;
    create index doc_index on document(qualified_file_name)
    indextype is ctxsys.context parameters ('datastore TRACKER_FILE_DATASTORE lexer TRACKER_LEXER')
    The table "document" contains an id column and a text column called "qualified_file_name". Qualified_file_name contains the full path and file name ("d:\temp\pptd\doc\1.doc", etc.)
    I am running Oracle 8.1.6 with InterMedia installed on NT 4.0. I have also tried to run the filter program ctxhx, but it only produces a zero length text file. Ctxhx is also very sporadic in that it does not always create an output file (buggy???).
    The error documentation does not give any helpful suggestions for resolving this problem. The cause is: failed to open a file. The action is: check whether file exist or access permission available. I checked both.
    Any suggestions would be greatly appreciated.

    <BLOCKQUOTE><font size="1" face="Verdana, Arial, Helvetica">quote:</font><HR>Originally posted by Mike Verdugo ([email protected]):
    I am getting the following error on 3 of 4 files for which I am trying to set up a simple text index:
    DRG-11101: failed to open file \drgit3
    Here are the steps/cmds I followed:
    begin
    ctx_ddl.create_preference('tracker_file_datastore','FILE_DATASTORE');
    ctx_ddl.set_attribute('tracker_file_datastore','PATH','d:\temp\pptd\doc');
    end;
    create index doc_index on document(qualified_file_name)
    indextype is ctxsys.context parameters ('datastore TRACKER_FILE_DATASTORE lexer TRACKER_LEXER')
    The table "document" contains an id column and a text column called "qualified_file_name". Qualified_file_name contains the full path and file name ("d:\temp\pptd\doc\1.doc", etc.)
    I am running Oracle 8.1.6 with InterMedia installed on NT 4.0. I have also tried to run the filter program ctxhx, but it only produces a zero length text file. Ctxhx is also very sporadic in that it does not always create an output file (buggy???).
    The error documentation does not give any helpful suggestions for resolving this problem. The cause is: failed to open a file. The action is: check whether file exist or access permission available. I checked both.
    Any suggestions would be greatly appreciated.<HR></BLOCKQUOTE>
    I forgot to mention that the file types are Microsoft Word documents (both Win 2000 and 97).

  • Errors reading documents when creating intermedia text indexs;

    The populating progress ended normally without error message . I check the log and found some reading errors happens during populating progress.
    The log is:
    12:56:45 07/19/00 begin logging
    12:56:58 07/19/00 populate index: CS.CTX_ADDRESS
    12:56:58 07/19/00 Begin document indexing
    12:56:58 07/19/00 100 documents indexed
    12:56:58 07/19/00 200 documents indexed
    12:56:58 07/19/00 300 documents indexed
    12:56:58 07/19/00 Errors reading documents: 0
    12:56:58 07/19/00 Index data for 342 documents to be written to database
    12:56:58 07/19/00 memory use: 305012
    12:56:58 07/19/00 index data written to database.
    12:56:58 07/19/00 End of document indexing. 342 documents indexed.
    Only 1 percente of all rows are populated.
    Somebody help me!!!

    How many rows in your $I?
    Which rows are not being populated?

  • Strange: Conditional Error in Intermedia Text Index Creation

    Hi All,
    I am facing a strange error while creating the Intermedia Text index on 8.1.6 release for NT 4.0.
    I have one database instance installed on the server. When i connect to Oracle through SQL plus as: connect username/password;
    The index creation works fine!
    But, if i connect using: username/password@servicename;
    The index creation does not work!
    The following error occurs.
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-20000:intermedia Text error:
    ORA-50704:Net8 listener is not running or cannot start external procedures
    ORA-28575:unable to open RPC connection to external procedure agent
    ORA-12154:TNS:could not resolve service name
    ORA-06512:at "CTXSYS.DRUE", line 126
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 54
    ORA-06512:at line 1
    Could anyone please help as to why it works without when connected without the service name but not otherwise?
    Thanking you in advance!
    Thanks and Regards
    Anurag Agarwal

    Hi All,
    I am facing a strange error while creating the Intermedia Text index on 8.1.6 release for NT 4.0.
    I have one database instance installed on the server. When i connect to Oracle through SQL plus as: connect username/password;
    The index creation works fine!
    But, if i connect using: username/password@servicename;
    The index creation does not work!
    The following error occurs.
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-20000:intermedia Text error:
    ORA-50704:Net8 listener is not running or cannot start external procedures
    ORA-28575:unable to open RPC connection to external procedure agent
    ORA-12154:TNS:could not resolve service name
    ORA-06512:at "CTXSYS.DRUE", line 126
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 54
    ORA-06512:at line 1
    Could anyone please help as to why it works without when connected without the service name but not otherwise?
    Thanking you in advance!
    Thanks and Regards
    Anurag Agarwal

  • Error creating a text Index

    When i tried to create a text index on my system (Oracle 8.1.6, RedHat Linux 6.2) i always get the same error:
    create index pkk on teste(maisumteste)indextype is ctxsys.context
    ERROR at line 1:
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-20000: interMedia Text error:
    ORA-06520: PL/SQL: Error loading external library
    ORA-06522: ctxsys: cannot open shared object file: No such file or directory
    ORA-06512: at "CTXSYS.DRUE", line 126
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 54
    ORA-06512: at line 1
    i'm a beginner in intermedia, so right now i'm stalled in this one, please help me.
    Thanks, in advance.
    Tony Cruz

    Raj Kr Pandit wrote:
    where is the issue?The issue is your code is apples and oranges:
    SQL> CREATE TABLE tab_1(aa nvarchar2(50) PRIMARY KEY,bb clob)
      2  /
    Table created.
    SQL> CREATE INDEX xtab_1_bb ON tab_1 (bb) INDEXTYPE IS CTXSYS.CONTEXT
      2  /
    CREATE INDEX xtab_1_bb ON tab_1 (bb) INDEXTYPE IS CTXSYS.CONTEXT
    ERROR at line 1:
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-20000: Oracle Text error:
    DRG-10528: primary keys of type NVARCHAR2 are not allowed
    ORA-06512: at "CTXSYS.DRUE", line 160
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 364
    SQL> SY.

  • Error When Creating Oracle Text index using Lexer Keyword

    Hi All,
    I am getting following error when i creating oracle text index using lexer & stoplist keyword.
    Pls Help me if any body know.
    Thanks in Advance.
    Error starting at line 1 in command:
    CREATE INDEX TXT_INX_TEXT_SEARCH ON TEXT_SEARCH (BFILE_DOC)
    Post INDEXTYPE IS "CTXSYS"."CONTEXT" LOCAL (
    PARTITION "BEFORE_2007" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)') ,
    PARTITION "Q1_2007" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q2_2007" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q3_2007" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q4_2007" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q1_2008" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q2_2008" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q3_2008" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q4_2008" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q1_2009" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q2_2009" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q3_2009" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q4_2009" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "THE_REST" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)')
    Error at Command Line:1 Column:13
    Error report:
    SQL Error: ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-20000: Oracle Text error:
    DRG-11000: invalid keyword LEXER
    ORA-06512: at "CTXSYS.DRUE", line 160
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 365
    29855. 00000 - "error occurred in the execution of ODCIINDEXCREATE routine"
    *Cause:    Failed to successfully execute the ODCIIndexCreate routine.
    *Action:   Check to see if the routine has been coded correctly.
    Regards,
    Jack R.

    Hi,
    it works if you put an extra PARAMETERS clause at the end so the creation looks like:
    CREATE INDEX TXT_INX_TEXT_SEARCH ON TEXT_SEARCH (BFILE_DOC)
    INDEXTYPE IS "CTXSYS"."CONTEXT" LOCAL (
    PARTITION "BEFORE_2007" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)') ,
    PARTITION "Q1_2007" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q2_2007" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q3_2007" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q4_2007" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q1_2008" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q2_2008" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q3_2008" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q4_2008" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q1_2009" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q2_2009" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q3_2009" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "Q4_2009" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)'),
    PARTITION "THE_REST" PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)')
    PARAMETERS ('LEXER dd_lexer STOPLIST dd_stoplist SYNC (ON COMMIT)') <== Added
    Hope this helps
    Herald ten Dam

  • INTERMEDIA TEXT INDEX를 사용하는 QUERY의 TUNING

    제품 : ORACLE SERVER
    작성날짜 : 2002-04-12
    INTERMEDIA TEXT INDEX를 사용하는 QUERY의 TUNING
    ===============================================
    Purpose
    Intermedia text를 사용하는 query의 속도를 향상시킬 수 있는 방안을
    알아보자.
    Explanation
    1. Make analyze all the table in the query
    text index를 이용하는 Query 안의 모든 Table을 analyze 해 주십시요.
    예를 들어 다음의 command를 이용할 수 있습니다.
    ANALYZE TABLE <table_name> COMPUTE STATISTICS;
    or
    ANALYZE TABLE <table_name> ESTIMATE STATISTICS 1000 ROWS;
    or
    ANALYZE TABLE <table_name> ESTIMATE STATISTICS 50 PERCENT;
    2. Using FIRST_ROWS hint
    더 좋은 response time 을 위해서 first_rows hint 를 사용해 보십시요.
    database에 기본적으로 설정된 optimizer mode는 choose mode입니다.
    이것은 전체 처리시간(throughput)을 가장 빠르게 하기 위한(all_rows mode)
    plan을 따르기 때문에 user의 입장에서는 first_rows 보다는 늦다고 느낄 수
    있습니다.
    Query에 다음과 같이 hint를 주고 performance를 확인해 보십시요.
    select /*+ FIRST_ROWS */ pk, col from ctx_tab
    where contains(txt_col, 'test', 1) > 0;
    단, first_rows hint를 이용하는 경우 자동으로 score 순서대로
    ordering 되지 않습니다. 왜냐하면 단어에 부합하는 문서를 찾는대로
    즉시 결과로 나타내 주기 때문입니다.
    3. Make sure text index is not fragmented
    insert, delete 가 많이 되는 table의 경우 index fragment를 제거해 주어야
    합니다. Index fragmentation 은 다음과 같이 확인할 수 있습니다.
    select count(*) from dr$<indexname>$i; -> A
    select count(*) from (select distinct(token_text) from dr$<indexname>$i); -> B
    위의 결과가 A/B 의 값이 3:1 보다 크면 optimize_index 를 실행해 주시는
    것이 좋습니다. 다음과 같은 command로 index optimization을 할 수 있습니다.
    alter index <index_name> rebuild online
    parameters('optimize full unlimited');
    index rebuild중에 online option을 주면 rebuild하는 중에도 계속 index를
    사용할 수 있게 됩니다. 하지만, 가능하면 사용자가 없을 때 rebuild하는 것이
    좋습니다.
    4. Check execution plan and sql trace.
    기본적인 여러 가지 작업들에도 속도가 별로 향상되지 않는다면, 직접
    sql trace를 떠서 Execution plan등을 확인해 보는 것이 필요합니다.
    예를 들어 SQL*PLUS에서 다음과 같이 sql trace를 뜹니다.
    alter session set timed_statistics=true;
    alter session set sql_trace=true;
    select ..... -> execute the query
    실행 후,
    exit
    user_dump_dest 에 지정된 directory에 trace 가 떨어지면 다음과 같은
    command로 tkprof 를 떠서 내용을 확인합니다.
    $ tkprof <tracefilename> <outputfilename> explain=username/password
    Referenc Documents
    Bulletin#10134 : SQL trace와 tkprof 사용 방법

  • Intermedia text index creation error

    My intermedia text was working fine, but now when create one index, it failed and it gave me the following error message:
    ERROR at line 1:
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-20000: ConText error:
    ORA-06520: PL/SQL: Error loading external library
    ORA-06522: ld.so.1: extprocPLSExtProc: fatal: libskgxp8.so: open failed: No such file or directory
    ORA-06512: at "CTXSYS.DRUE", line 122
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 34
    ORA-06512: at line 1
    The listener itself is fine, is it because some library need to be re-created?
    null

    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Alexander Bogomolov ([email protected]):
    I've installed Intermedia text. During sample index creation i've get following error messages:
    ORA-06520: PL/SQL: Error loading external library
    ORA-06522: Unable to load DLL
    ORA-06512: at "CTXSYS.DRUE", line 126
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 54
    ORA-06512: at line 1...
    seems to be incorrect NET8 settings. How can I solve this problem?
    thanks.
    Sorry for bad English. regards!<HR></BLOCKQUOTE>
    *** check your listener.ora file
    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (SID_NAME = PLSExtProc)
    (ORACLE_HOME = oracle_home)
    (PROGRAM = extproc)
    (SID_DESC =
    (GLOBAL_DBNAME = global dbname)
    (ORACLE_HOME = oracle_home)
    (SID_NAME = sidname)
    for the correct location of extproc
    null

  • Intermedia text search error for file system

    I would like to search a text from a file. store in the file system. I have done the following procedures but when i create i get error.
    BEGIN
    CTX_DDL.CREATE_PREFERENCE('search_docroot_pref','FILE_DATASTORE');
    CTX_DDL.SET_ATTRIBUTE('search_docroot_pref','path','c:/temp/abc');
    END;
    Now when i create INDEX with following syntex
    CREATE INDEX mysearch_ind ON mytable(mycolumn) INDEXTYPE IS
    CTXSYS.context parameters('datastore search_docroot_pref');
    I get the following errors.
    ERROR at line 1:
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-20000: interMedia Text error:
    DRG-50704: Net8 listener is not running or cannot start external procedures
    ORA-28575: unable to open RPC connection to external procedure agent
    ORA-06512: at "CTXSYS.DRUE", line 126
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 54
    ORA-06512: at line 1
    Can any body tell me where i am wrong.
    Thanks,

    Hi
    I was aslo facing same problem.My net8 connection and listner is aslo ok. but getting same errors.
    Raju

  • Create Oracle Text Index from Java via JDBC

    Hi, I have a question relevant to creation of the Text Index in Oracle Text via Java JDBC.
    In Java I create client application and I connect to remote Oracle server. (there is Oracle
    10g Enterprise Edition 10.2.0.3.0 on Debian Linux OS). In Java I create query:
    CREATE INDEX index_name ON source_tab(text) indextype is ctxsys.context
    parameters('datastore ctxsys.file_datastore filter ctxsys.null_filter');
    and I start it by:
    PreparedStatement stmt = db.prepareStatement(query);
    ResultSet rs = stmt.executeQuery();
    There is problem that Text Index is created empty and when I write out error log then:
    DRG-11513: unable to open or write to file "path"
    I have on my computer Oracle XE 10g (Windows XP OS) here this application in Java functions
    without problems. Without problems it´s with that same query in SQLPlus when I connect at
    this remote Oracle server via PuTTY.
    Do you know anybody where could be error? Or at worst case where find I more detailed
    manual about JDBC Oracle mainly possible errors and problems with compatibility?

    Does it work if you don't use "file_datastore"?
    Eg. try the following in sqlplus:
    create table t (text varchar2(2000));
    insert into t values ('hello world');
    create index ti on t(text) indextype is ctxsys.context;
    select * from t where contains (text, 'hello') > 0;
    Then drop the index ti and try the same "create index" through JDBC. Does that work?
    If so, then we have some kind of issue with the file_datastore. I assume you are aware that the file will be read by the SERVER, not from the client?
    So if your database resides on a Linux box, but you are calling from a Java program on a windows PC, the file names in source_tab(text) must be in Linux format, and must refer to files which are available on the Linux server (and readable by the owner of the Oracle database process).
    So /home/me/file.txt might work, but C:\Documents\file.txt will not.

  • Oracle Text Index Error - DRG-10700: preference does not exist: CTXSYS.DEFA

    Hi we are having a Oracle 11g db.And we have installed CTX SYS package and provided the grants to the required schema.
    But while creating the oracle text index, following error is thrown:
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-20000: Oracle Text error:
    DRG-10700: preference does not exist: CTXSYS.DEFAULT_LEXER
    ORA-06512: at "CTXSYS.DRUE", line 160
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 365
    Following grnats are given :
    GRANT EXECUTE ON CTXSYS.CTX_DDL TO <schema_name>;
    GRANT APPOWN TO <schema_name>;
    GRANT CTXAPP TO <schema_name>;
    I have verifyed the ctxsys.CTX_PREFERENCES view which is having an entry as :
    SELECT PRE_OWNER, PRE_NAME
    FROM CTXSYS.CTX_PREFERENCES
    WHERE PRE_NAME = 'DEFAULT_LEXER';
    The Result is :
    PRE_OWNER     PRE_NAME
    SYS     DEFAULT_LEXER
    Can you please assist if there is a way to update the permission on this DEFAULT_LEXER preference to set the PRE_OWNER as CTXSYS ?
    Thanks

    That's odd. If I run the same query I see:
    SQL> SELECT PRE_OWNER, PRE_NAME
      2  FROM CTXSYS.CTX_PREFERENCES
      3  WHERE PRE_NAME = 'DEFAULT_LEXER';
    PRE_OWNER                      PRE_NAME
    CTXSYS                         DEFAULT_LEXERAre all your defaults like thsi? What do you see if you run
    select pre_owner, pre_name from ctxsys.ctx_preferences where pre_name like 'DEFAULT%';
    It would be easy enough to update the underlying table DR$PREFERENCES to fix the owner, but who knows what else might be wrong.
    Has this database been updated from a 9i installation by any chance?

  • Trouble creating Oracle Text index

    Hey all,
    I am having trouble creating an Oracle Text index. I am receiving the following error when I try to sync the index after inserting numerous rows (@170,000). I have also tried to insert the rows and then create the index afterword. See below.
    ORACLE_TEXT>insert into varchar_test_ot select doc from varchar_test;
    171327 rows created.
    Elapsed: 00:06:40.08
    ORACLE_TEXT>exec ctx_ddl.sync_index('VT_TEST_IDX_OT');
    BEGIN ctx_ddl.sync_index('VT_TEST_IDX_OT'); END;
    ERROR at line 1:
    ORA-20000: Oracle Text error:
    DRG-50857: oracle error in drekmap (lob write)
    ORA-22990: LOB locators cannot span transactions
    ORA-06512: at "CTXSYS.DRUE", line 157
    ORA-06512: at "CTXSYS.CTX_DDL", line 1328
    ORA-06512: at line 1
    Elapsed: 00:02:09.07

    CREATE TABLE varchar_test
    (doc VARCHAR2(4000)
    CREATE TABLE varchar_test_ot
    (doc VARCHAR2(4000)
    begin
    ctx_ddl.create_preference('storage_pref','BASIC_STORAGE');
    ctx_ddl.set_attribute('storage_pref', 'I_TABLE_CLAUSE',
    'tablespace ot_test_idx_space storage (initial 1M next 1M)');
    ctx_ddl.set_attribute('storage_pref', 'K_TABLE_CLAUSE',
    'tablespace ot_test_idx_space storage (initial 1M next 1M)');
    ctx_ddl.set_attribute('storage_pref', 'R_TABLE_CLAUSE',
    'tablespace ot_test_idx_space storage (initial 1M next 1M)');
    ctx_ddl.set_attribute('storage_pref', 'N_TABLE_CLAUSE',
    'tablespace ot_test_idx_space storage (initial 1M next 1M)');
    ctx_ddl.set_attribute('storage_pref', 'I_INDEX_CLAUSE',
    'tablespace ot_test_idx_space storage (initial 1M next 1M)');
    ctx_ddl.set_attribute('storage_pref', 'P_TABLE_CLAUSE',
    'tablespace ot_test_idx_space storage (initial 1M next 1M)');
    ctx_ddl.create_section_group('auto','AUTO_SECTION_GROUP');
    ctx_ddl.create_preference('mywordlist', 'BASIC_WORDLIST');
    ctx_ddl.set_attribute('mywordlist','SUBSTRING_INDEX', 'YES');
    end;
    CREATE INDEX vt_test_idx_ot
    ON varchar_test_ot(doc)
    INDEXTYPE IS CTXSYS.CONTEXT
    PARAMETERS ('datastore ctxsys.default_datastore
    filter ctxsys.null_filter
    wordlist mywordlist
    storage storage_pref
    section group auto
    memory 50M');

  • Help with creating oracle text index on 2 columns with partial html data

    Hi,
    I need to create an oracle text index on 2 columns.
    TITLE - varchar(255) = contains plain text data
    DESCRIPTION - CLOB = contains partial HTML data
    This is what I created.
    begin
    ctx_ddl.create_preference ('Title_Description_Pref', 'MULTI_COLUMN_DATASTORE');
    ctx_ddl.set_attribute('Title_Description_Pref', 'columns', 'TITLE, DESCRIPTION');
    end;
    begin
    ctx_ddl.create_preference ('bid_lexer', 'BASIC_LEXER');
    ctx_ddl.set_attribute('bid_lexer', 'index_stems', 'ENGLISH');
    ctx_ddl.create_section_group('htmgroup', 'HTML_SECTION_GROUP');
    end;
    create index Bid_Title_Index on Bid(title) indextype is ctxsys.context parameters ('LEXER bid_lexer sync (every "sysdate+(1/24)")');
    create index Bid_Title_Desc_Index on Bid(description) indextype is ctxsys.context parameters ('LEXER bid_lexer DATASTORE Title_Description_Pref sync (every "sysdate+(1/24)") filter ctxsys.null_filter section group htmgroup');
    The problem is when I do a CONTAINS(description, '$(auction)')>0. I get results where the descriptions have the "auction" word (which is correct). But, the results also returned rows where the search word is inside an IMG tag. e.g. <img src="http://auction.de/120483" alt="Auction Logo"/>.
    What I would like is to exclude rows where the search word is inside HTML tag attributes, results expected are rows having <a>Auction</a> or <p>For Auction</p> ... etc. Basically stripping the html tags and leave the text contents.
    I'd appreciate some input.
    Thanks,
    Amiel

    Hi,
    I need to create an oracle text index on 2 columns.
    TITLE - varchar(255) = contains plain text data
    DESCRIPTION - CLOB = contains partial HTML data
    This is what I created.
    begin
    ctx_ddl.create_preference ('Title_Description_Pref', 'MULTI_COLUMN_DATASTORE');
    ctx_ddl.set_attribute('Title_Description_Pref', 'columns', 'TITLE, DESCRIPTION');
    end;
    begin
    ctx_ddl.create_preference ('bid_lexer', 'BASIC_LEXER');
    ctx_ddl.set_attribute('bid_lexer', 'index_stems', 'ENGLISH');
    ctx_ddl.create_section_group('htmgroup', 'HTML_SECTION_GROUP');
    end;
    create index Bid_Title_Index on Bid(title) indextype is ctxsys.context parameters ('LEXER bid_lexer sync (every "sysdate+(1/24)")');
    create index Bid_Title_Desc_Index on Bid(description) indextype is ctxsys.context parameters ('LEXER bid_lexer DATASTORE Title_Description_Pref sync (every "sysdate+(1/24)") filter ctxsys.null_filter section group htmgroup');
    The problem is when I do a CONTAINS(description, '$(auction)')>0. I get results where the descriptions have the "auction" word (which is correct). But, the results also returned rows where the search word is inside an IMG tag. e.g. <img src="http://auction.de/120483" alt="Auction Logo"/>.
    What I would like is to exclude rows where the search word is inside HTML tag attributes, results expected are rows having <a>Auction</a> or <p>For Auction</p> ... etc. Basically stripping the html tags and leave the text contents.
    I'd appreciate some input.
    Thanks,
    Amiel

  • Creating interMedia substring index on a CLOB that contains XML

    I have a CLOB column that has an existing XML_SECTION_GROUP index on certain tags within the XML content of the CLOB. (see script below)
    begin
    ctx_ddl.create_section_group('XMLDOC','XML_SECTION_GROUP');
    end;
    begin
    ctx_ddl.add_zone_section ('XMLDOC','title','title');
    ctx_ddl.add_zone_section('XMLDOC','keywords','keywords');
    ctx_ddl.add_zone_section('XMLDOC','author','author');
    end;
    create index xmldoc_idx on xml_documents(xmldoc)
    indextype is ctxsys.context
    parameters ('section group xmldoc') ;
    I have a requirement to search on the 'author' zone section by the first letter only. I figure a substring index is the way to go but I'm not sure of the syntax to create a substring index. Especially when I have already declared a SECTION_GROUP preference on this column and I would need to create a WORDLIST preference as well I think. Can someone help me out here?
    null

    Here is the answer from Oracle Text Help:
    "the main problem here is that you cannot apply that fancy substring
    processing just to the author section -- it will apply to everything,
    which will probably blow up the index size.
    Anything you do will require reindexing the documents, so you cannot
    really get around having to rebuild the index entirely.
    Here are various ways to tackle the problem:
    1. do nothing. Query just like: Z% WITHIN AUTHOR
    PRO: don't have to rebuild index
    CON: query is slow. some queries cannot be executed due to
    wildcard maxterms limits.
    2. create a wordlist preference with PREFIX_INDEX set to TRUE,
    PREFIX_MIN_LENGTH set to 1 and PREFIX_MAX_LENGTH set to 1.
    Query looks like: Z% WITHIN AUTHOR
    PRO: moderately fast query
    CON: must be on 8.1.7 or above
    get a lot of junk from words from other sections
    3. 2) as above, plus make AUTHOR, KEYWORDS, TITLE field sections
    PRO: faster query than 2)
    CON: field sections are less flexible w.r.t. nesting and
    repeating occurrences
    4. use a user_datastore or procedure_filter to transform the data
    so that <AUTHOR>Steven King</AUTHOR> becomes
    <AUTHORINIT>AIK</AUTHORINIT><AUTHOR>Steven King<AUTHOR>
    Use field section for AUTHORINIT and query becomes:
    AIK within AUTHORINIT (I used AIK instead of just K so that you
    don't have to make I and A non-stopwords)
    PRO: fastest query, smallest index
    CON: most work
    have to massage data so slows down indexing"

  • Create a text index on multiple tables

    I have read the same forum questions a thousand times about doing this and the only thing they show examples of is using multiple columns in one table.
    Here is what I have:
    create table documents_a
    (id number,
    text blob);
    create table documents_b
    (id number,
    text blob);
    create table documents_c
    (id number,
    text blob);
    I want to be able to do a text search over all three tables on the blob column. I can't use the multi_column_datastore because from what I read this can only be used with one table.
    I eventually want to be able to bring up a snippet of the text that contains the keywords and a link to the actual document.
    How do I build a text index that includes each blob column from each of the three tables?

    OK so I created the materialized view
    create materialized view alltabs as
    select a.id, a.text, b.id, b.text, c.id, c.text
    from tablea a, tableb b, tablec c;
    and I created the following
    ctx_ddl.create_preference(my_multi', "MULTI_COLUMN_DATASTORE');
    ctx_ddl.set_attribute('my_multi','columns','a_document, b_document, c_document');
    Then I attempted but I am not sure what column name to put in the pararens?
    create index multi_tab on alltabs(????)
    indextype is ctxsys.context
    parameters('datastore my_multi sync(on commit)');
    I saw a dummy column created in most of the internet examples but just exactly what gets created here? I want to create a multi column index so didn't I already tell it which columns up above?

Maybe you are looking for