Oracle Text apps

Hi Friends,
Supposing i created a new user USER1....how do i grant all the
necessary privileges from ctxsys schema/user in order to be
able to run an Oracle Text Apps?
Thanks

Hi Ruma,
What tool are you using to product your reports? Perhaps the square is a page break symbol introduced by your print process? What process is the text file going through to get to the point where the square occurs?
Regards,
Gareth
Blog: http://garethroberts.blogspot.com/

Similar Messages

  • Can not find Oracle Text/Knowledge Base product

    Hi Friends,
    Re: can not install demo PRESIDENTIAL INAUGURAL ADDRESSES
    I am using Oracle 10.2.0.1.
    I tried to look for the Oracle Text on DB Companion CD but it is not there.
    I only found (1. Apache Stand Alone 2.Workflow Middle Tier).
    Do I need to Install it from 10g Release 1 CD?
    Thanks

    By tha way if i create a user user1....how do i grant
    all the
    necessary privileges from ctxsys schema/user in order
    to be
    able to run an Oracle Text Apps?You shouldn't have to do anything. When you create a new workspace, the workspace user (the oracle account) has the right privileges.
    You can just create a new workspace and run the following example:
    CREATE TABLE TEST(nr NUMBER PRIMARY KEY, test_text VARCHAR2(500))
    INSERT INTO TEST
         VALUES (1, 'This is a test');
    INSERT INTO TEST
         VALUES (2, 'of the InterMedia text installation')
    COMMIT
    CREATE INDEX test_idx ON TEST(test_text) INDEXTYPE IS ctxsys.CONTEXT
    SELECT nr, test_text
      FROM TEST
    WHERE contains (test_text, 'installation') > 0
    Yes its 10.2. the welcome web login window shows
    version 10.2Sorry, but this is not what I have asked you to do (already twice) . I am getting a bit frustrated here and I really want to help you.
    But you see, sometimes it is only details that mess up everything.
    I assume you have mixed the versions of the base install and the companion cd install disk. I might be wrong in my assumptions but we have to get clear on the facts.
    I cannot look at your machine so you have to help me to be able to help you.
    Please do the following
    1) run the following command on your instance as a dba (sys or system):
    SQL> select version from v$instance;
    VERSION
    10.2.0.1.02) start the universal installer of your companion cd and post the output.
    Preparing to launch Oracle Universal Installer from
    /tmp/OraInstall2006-01-11_10-32-25AM. Please wait ...[oracle@daust companion]$
    Oracle Universal Installer, Version 10.2.0.1.0 Production
    Copyright (C) 1999, 2005, Oracle. All rights reserved.As I've said, I might be wrong in my assumptions. So, prove me wrong and let's move ahead :).
    ~Dietmar.

  • APEX app using Oracle Text  to index pages that require authorzation

    Hi Gurus and APEX Dev team
    My team need to develop an APEX App that will index all our documents spread across various servers. Some of the documents require Single sign on access (e.g. KIX.oraclecorp.com) and some require other authorization methods (e.g. Metalink) . The Question is , Is it possible to index the pages that require authorization using Oracle text. If yes How? I have implemented the demo app which can index pages that do not require authorization.
    Thanks a million
    regards
    Bala

    Hello,
    Unless I misunderstand you, the fact that the pages require authentication doesn't really matter, it is the underlying data you want to index correct? If so then you would index them in exactly the same way that you would index any table data using Oracle Text/interMedia.
    John.
    Blog: http://jes.blogs.shellprompt.net
    Work: http://www.apex-evangelists.com
    Author of Pro Application Express: http://tinyurl.com/3gu7cd
    REWARDS: Please remember to mark helpful or correct posts on the forum, not just for my answers but for everyone!

  • Oracle Text Demo App

    When I try to install the Presidential Inaugural Addresses, I receive the following error message.
    ORA-20001: This demonstration can only be installed into an Oracle database which has the English preferences loaded for Oracle Text. Please contact your administrator.
    I have duplicated this on two of our HTMLDB instances.
    What change(s) will I need to make?
    Thanks,
    Jennifer

    Jennifer,
    See our FAQ entry here:
    http://www.oracle.com/technology/products/database/htmldb/install_faq.html#presidents
    Sergio

  • Pre-loading Oracle text in memory with Oracle 12c

    There is a white paper from Roger Ford that explains how to load the Oracle index in memory : http://www.oracle.com/technetwork/database/enterprise-edition/mem-load-082296.html
    In our application, Oracle 12c, we are indexing a big XML field (which is stored as XMLType with storage secure file) with the PATH_SECTION_GROUP. If I don't load the I table (DR$..$I) into memory using the technique explained in the white paper then I cannot have decent performance (and especially not predictable performance, it looks like if the blocks from the TOKEN_INFO columns are not memory then performance can fall sharply)
    But after migrating to oracle 12c, I got a different problem, which I can reproduce: when I create the index it is relatively small (as seen with ctx_report.index_size) and by applying the technique from the whitepaper, I can pin the DR$ I table into memory. But as soon as I do a ctx_ddl.optimize_index('Index','REBUILD') the size becomes much bigger and I can't pin the index in memory. Not sure if it is bug or not.
    What I found as work-around is to build the index with the following storage options:
    ctx_ddl.create_preference('TEST_STO','BASIC_STORAGE');
    ctx_ddl.set_attribute ('TEST_STO', 'BIG_IO', 'YES' );
    ctx_ddl.set_attribute ('TEST_STO', 'SEPARATE_OFFSETS', 'NO' );
    so that the token_info column will be stored in a secure file. Then I can change the storage of that column to put it in the keep buffer cache, and write a procedure to read the LOB so that it will be loaded in the keep cache. The size of the LOB column is more or less the same as when creating the index without the BIG_IO option but it remains constant even after a ctx_dll.optimize_index. The procedure to read the LOB and to load it into the cache is very similar to the loaddollarR procedure from the white paper.
    Because of the SDATA section, there is a new DR table (S table) and an IOT on top of it. This is not documented in the white paper (the white paper was written for Oracle 10g). In my case this DR$ S table is much used, and the IOT also, but putting it in the keep cache is not as important as the token_info column of the DR I table. A final note: doing SEPARATE_OFFSETS = 'YES' was very bad in my case, the combined size of the two columns is much bigger than having only the TOKEN_INFO column and both columns are read.
    Here is an example on how to reproduce the problem with the size increasing when doing ctx_optimize
    1. create the table
    drop table test;
    CREATE TABLE test
    (ID NUMBER(9,0) NOT NULL ENABLE,
    XML_DATA XMLTYPE
    XMLTYPE COLUMN XML_DATA STORE AS SECUREFILE BINARY XML (tablespace users disable storage in row);
    2. insert a few records
    insert into test values(1,'<Book><TITLE>Tale of Two Cities</TITLE>It was the best of times.<Author NAME="Charles Dickens"> Born in England in the town, Stratford_Upon_Avon </Author></Book>');
    insert into test values(2,'<BOOK><TITLE>The House of Mirth</TITLE>Written in 1905<Author NAME="Edith Wharton"> Wharton was born to George Frederic Jones and Lucretia Stevens Rhinelander in New York City.</Author></BOOK>');
    insert into test values(3,'<BOOK><TITLE>Age of innocence</TITLE>She got a prize for it.<Author NAME="Edith Wharton"> Wharton was born to George Frederic Jones and Lucretia Stevens Rhinelander in New York City.</Author></BOOK>');
    3. create the text index
    drop index i_test;
      exec ctx_ddl.create_section_group('TEST_SGP','PATH_SECTION_GROUP');
    begin
      CTX_DDL.ADD_SDATA_SECTION(group_name => 'TEST_SGP', 
                                section_name => 'SData_02',
                                tag => 'SData_02',
                                datatype => 'varchar2');
    end;
    exec ctx_ddl.create_preference('TEST_STO','BASIC_STORAGE');
    exec  ctx_ddl.set_attribute('TEST_STO','I_TABLE_CLAUSE','tablespace USERS storage (initial 64K)');
    exec  ctx_ddl.set_attribute('TEST_STO','I_INDEX_CLAUSE','tablespace USERS storage (initial 64K) compress 2');
    exec  ctx_ddl.set_attribute ('TEST_STO', 'BIG_IO', 'NO' );
    exec  ctx_ddl.set_attribute ('TEST_STO', 'SEPARATE_OFFSETS', 'NO' );
    create index I_TEST
      on TEST (XML_DATA)
      indextype is ctxsys.context
      parameters('
        section group   "TEST_SGP"
        storage         "TEST_STO"
      ') parallel 2;
    4. check the index size
    select ctx_report.index_size('I_TEST') from dual;
    it says :
    TOTALS FOR INDEX TEST.I_TEST
    TOTAL BLOCKS ALLOCATED:                                                104
    TOTAL BLOCKS USED:                                                      72
    TOTAL BYTES ALLOCATED:                                 851,968 (832.00 KB)
    TOTAL BYTES USED:                                      589,824 (576.00 KB)
    4. optimize the index
    exec ctx_ddl.optimize_index('I_TEST','REBUILD');
    and now recompute the size, it says
    TOTALS FOR INDEX TEST.I_TEST
    TOTAL BLOCKS ALLOCATED:                                               1112
    TOTAL BLOCKS USED:                                                    1080
    TOTAL BYTES ALLOCATED:                                 9,109,504 (8.69 MB)
    TOTAL BYTES USED:                                      8,847,360 (8.44 MB)
    which shows that it went from 576KB to 8.44MB. With a big index the difference is not so big, but still from 14G to 19G.
    5. Workaround: use the BIG_IO option, so that the token_info column of the DR$ I table will be stored in a secure file and the size will stay relatively small. Then you can load this column in the cache using a procedure similar to
    alter table DR$I_TEST$I storage (buffer_pool keep);
    alter table dr$i_test$i modify lob(token_info) (cache storage (buffer_pool keep));
    rem: now we must read the lob so that it will be loaded in the keep buffer pool, use the prccedure below
    create or replace procedure loadTokenInfo is
      type c_type is ref cursor;
      c2 c_type;
      s varchar2(2000);
      b blob;
      buff varchar2(100);
      siz number;
      off number;
      cntr number;
    begin
        s := 'select token_info from  DR$i_test$I';
        open c2 for s;
        loop
           fetch c2 into b;
           exit when c2%notfound;
           siz := 10;
           off := 1;
           cntr := 0;
           if dbms_lob.getlength(b) > 0 then
             begin
               loop
                 dbms_lob.read(b, siz, off, buff);
                 cntr := cntr + 1;
                 off := off + 4096;
               end loop;
             exception when no_data_found then
               if cntr > 0 then
                 dbms_output.put_line('4K chunks fetched: '||cntr);
               end if;
             end;
           end if;
        end loop;
    end;
    Rgds, Pierre

    I have been working a lot on that issue recently, I can give some more info.
    First I totally agree with you, I don't like to use the keep_pool and I would love to avoid it. On the other hand, we have a specific use case : 90% of the activity in the DB is done by queuing and dbms_scheduler jobs where response time does not matter. All those processes are probably filling the buffer cache. We have a customer facing application that uses the text index to search the database : performance is critical for them.
    What kind of performance do you have with your application ?
    In my case, I have learned the hard way that having the index in memory (the DR$I table in fact) is the key : if it is not, then performance is poor. I find it reasonable to pin the DR$I table in memory and if you look at competitors this is what they do. With MongoDB they explicitly says that the index must be in memory. With elasticsearch, they use JVM's that are also in memory. And effectively, if you look at the awr report, you will see that Oracle is continuously accessing the DR$I table, there is a SQL similar to
    SELECT /*+ DYNAMIC_SAMPLING(0) INDEX(i) */    
    TOKEN_FIRST, TOKEN_LAST, TOKEN_COUNT, ROWID    
    FROM DR$idxname$I
    WHERE TOKEN_TEXT = :word AND TOKEN_TYPE = :wtype    
    ORDER BY TOKEN_TEXT,  TOKEN_TYPE,  TOKEN_FIRST
    which is continuously done.
    I think that the algorithm used by Oracle to keep blocks in cache is too complex. A just realized that in 12.1.0.2 (was released last week) there is finally a "killer" functionality, the in-memory parameters, with which you can pin tables or columns in memory with compression, etc. this looks ideal for the text index, I hope that R. Ford will finally update his white paper :-)
    But my other problem was that the optimize_index in REBUILD mode caused the DR$I table to double in size : it seems crazy that this was closed as not a bug but it was and I can't do anything about it. It is a bug in my opinion, because the create index command and "alter index rebuild" command both result in a much smaller index, so why would the guys that developped the optimize function (is it another team, using another algorithm ?) make the index two times bigger ?
    And for that the track I have been following is to put the index in a 16K tablespace : in this case the space used by the index remains more or less flat (increases but much more reasonably). The difficulty here is to pin the index in memory because the trick of R. Ford was not working anymore.
    What worked:
    first set the keep_pool to zero and set the db_16k_cache_size to instead. Then change the storage preference to make sure that everything you want to cache (mostly the DR$I) table come in the tablespace with the non-standard block size of 16k.
    Then comes the tricky part : the pre-loading of the data in the buffer cache. The problem is that with Oracle 12c, Oracle will use direct_path_read for FTS which basically means that it bypasses the cache and read directory from file to the PGA !!! There is an event to avoid that, I was lucky to find it on a blog (I can't remember which, sorry for the credit).
    I ended-up doing that. the events to 10949 is to avoid the direct path reads issue.
    alter session set events '10949 trace name context forever, level 1';
    alter table DR#idxname0001$I cache;
    alter table DR#idxname0002$I cache;
    alter table DR#idxname0003$I cache;
    SELECT /*+ FULL(ITAB) CACHE(ITAB) */ SUM(TOKEN_COUNT),  SUM(LENGTH(TOKEN_INFO)) FROM DR#idxname0001$I;
    SELECT /*+ FULL(ITAB) CACHE(ITAB) */ SUM(TOKEN_COUNT),  SUM(LENGTH(TOKEN_INFO)) FROM DR#idxname0002$I;
    SELECT /*+ FULL(ITAB) CACHE(ITAB) */ SUM(TOKEN_COUNT),  SUM(LENGTH(TOKEN_INFO)) FROM DR#idxname0003$I;
    SELECT /*+ INDEX(ITAB) CACHE(ITAB) */  SUM(LENGTH(TOKEN_TEXT)) FROM DR#idxname0001$I ITAB;
    SELECT /*+ INDEX(ITAB) CACHE(ITAB) */  SUM(LENGTH(TOKEN_TEXT)) FROM DR#idxname0002$I ITAB;
    SELECT /*+ INDEX(ITAB) CACHE(ITAB) */  SUM(LENGTH(TOKEN_TEXT)) FROM DR#idxname0003$I ITAB;
    It worked. With a big relief I expected to take some time out, but there was a last surprise. The command
    exec ctx_ddl.optimize_index(idx_name=>'idxname',part_name=>'partname',optlevel=>'REBUILD');
    gqve the following
    ERROR at line 1:
    ORA-20000: Oracle Text error:
    DRG-50857: oracle error in drftoptrebxch
    ORA-14097: column type or size mismatch in ALTER TABLE EXCHANGE PARTITION
    ORA-06512: at "CTXSYS.DRUE", line 160
    ORA-06512: at "CTXSYS.CTX_DDL", line 1141
    ORA-06512: at line 1
    Which is very much exactly described in a metalink note 1645634.1 but in the case of a non-partitioned index. The work-around given seemed very logical but it did not work in the case of a partitioned index. After experimenting, I found out that the bug occurs when the partitioned index is created with  dbms_pclxutil.build_part_index procedure (this enables  enables intra-partition parallelism in the index creation process). This is a very annoying and stupid bug, maybe there is a work-around, but did not find it on metalink
    Other points of attention with the text index creation (stuff that surprised me at first !) ;
    - if you use the dbms_pclxutil package, then the ctx_output logging does not work, because the index is created immediately and then populated in the background via dbms_jobs.
    - this in combination with the fact that if you are on a RAC, you won't see any activity on the box can be very frightening : this is because oracle can choose to start the workers on the other node.
    I understand much better how the text indexing works, I think it is a great technology which can scale via partitioning. But like always the design of the application is crucial, most of our problems come from the fact that we did not choose the right sectioning (we choosed PATH_SECTION_GROUP while XML_SECTION_GROUP is so much better IMO). Maybe later I can convince the dev to change the sectionining, especially because SDATA and MDATA section are not supported with PATCH_SECTION_GROUP (although it seems to work, even though we had one occurence of a bad result linked to the existence of SDATA in the index definition). Also the whole problematic of mixed structured/unstructured searches is completly tackled if one use XML_SECTION_GROUP with MDATA/SDATA (but of course the app was written for Oracle 10...)
    Regards, Pierre

  • Bad Query Performance in Oracle Text

    Hello everyone, I have the following problem:
    I have a table, TABLE_A from now on, a table of more or less 1,000.000 rows, with a CONTEXT index, using FILE_DATASTORE, CTXSYS.DEFAULT_STORAGE, CTXSYS.NULL_FILTER, CTXSYS.BASIC_LEXER and querying the index in the following way:
    SELECT /*+FIRST_ROWS*/ A.ID, B.ID2, SCORE(1) FROM TABLE_A A, TABLE_B WHERE A.ID = B.ID AND CONTAINS(A.PATH, '<SOME KW>', 1) > 0 ORDER BY SCORE(1) DESC
    where TABLE_B has another 1,000.000 rows.
    The problem is that the query response time is much higher after some time of inactivity regarding those tables. How can I avoid this behavior?. The fact is that those inactivity times (not more than 20min) are core to my application, so I always get long long response times for my queries.
    Is there any cache or cache time parameter that affects this behavior? I have checked the Oracle Text documentation without finding anything about that...
    More data: I am using Oracle 9.2.0.1, but I have tested with the latest patches an the behavior is the same...
    Thank you very much in advance.

    Pablo,
    This appears to be a generic database or OS issue, not a Text specific issue. It really depends on what your application is doing.
    If your application is doing some other database activity such as queries or DMLs on other non-text tables, chances are Oracle Text related data blocks are being aged out of cache. You can either increase the db_cache_size init
    parmater or try to keep the text tables and index tables blocks in cache using ALTER TABLE commands.
    If your app is doing NON-database activity, then chances are your application is taking up much of the machine's physical memory such that OS is swapping ORACLE out of the memory. In which case, you may want to consider to add more memory to the machine or have ORACLE run on a separate machine by itself.

  • Oracle text in 9.2

    Hi
    I am trying to make a query run against a table as follows
    SQL> desc FILES_INCLUDED;
    Name Null? Type
    PID NOT NULL VARCHAR2(16)
    FILENAME NOT NULL VARCHAR2(240)
    SQL> select count(*) from FILES_INCLUDED;
    COUNT(*)
    5719417
    SQL>
    where PID & FILENAME essentially contains all the files delivered by a particular patch, ie
    123456-01 woudl be pid and FILENAME might be
    /usr/bin/ls, so 123456-01 might have multiple entries, one row for each deliverable i.e.
    SQL> select count(*) from FILES_INCLUDED where PID='xxxxxx-xx';
    COUNT(*)
    969
    SQL>
    I know this is poor really, but that is what this looks like so short of rewriting apps, that is the way it is.
    Anyway users want to do
    select distinct PID from FILES_INCLUDED where FILENAME like '%bin/ls%';
    now this just takes up to one minute to run ( not unexpected that really )
    So I recommended oracle text as perhaps a better way,
    I set this up via
    begin
    ctx_ddl.create_preference('mywordlist', 'BASIC_WORDLIST');
    ctx_ddl.set_attribute('mywordlist','PREFIX_INDEX','true');
    ctx_ddl.set_attribute('mywordlist','SUBSTRING_INDEX', 'YES');
    ctx_ddl.set_attribute('mywordlist','WILDCARD_MAXTERMS', '15000');
    end;
    and this works to a degree, but is there a way to know upfront, how to avoid getting
    DRG-51030: wildcard query expansion resulted in too many terms
    that is what is the minimum number of chars that one can use ( how to determine this )
    ie
    select distinct pid from files_included where (contains (filename,'/bin/%',1)>0)
    gets a DRG-51030
    I can query
    select count(*) from dr$FILE_NAME_INX$i;
    select count(*) from dr$FILE_NAME_INX$p;
    to get an idea of the number of tokens, but not sure how to make a query run on this kind of data that is foolproof.
    The use case is for users to enter
    %ls% and get back the PID's that deliver %ls%.
    Enda

    It looks like you are wanting to search by sub-directory names or a combination of sub-directory names. By default, Oracle Text views the directory delimiter / as white space, so the individual sub-directories are tokenized. Therefore, you don't need the wildcards or / to do your searches. Please see the example below.
    SCOTT@orcl_11g> create table files_included
      2    (pid       varchar2 (16) not null,
      3       filename  varchar2 (40) not null)
      4  /
    Table created.
    SCOTT@orcl_11g> insert all
      2  into files_included values
      3    ('123456-01', '/usr/bin/ls/a')
      4  into files_included values
      5    ('123456-02', '/usr/bin/ls/b')
      6  into files_included values
      7    ('123456-03', '/usr/x/ls/a')
      8  into files_included values
      9    ('123456-02', '/usr/bin/x/b')
    10  into files_included values
    11    ('654321', '/usr/bin/other')
    12  select * from dual
    13  /
    5 rows created.
    SCOTT@orcl_11g> create index myindex
      2  on files_included (filename)
      3  indextype is ctxsys.context
      4  /
    Index created.
    SCOTT@orcl_11g> select token_text
      2  from   dr$myindex$i
      3  /
    TOKEN_TEXT
    B
    BIN
    LS
    OTHER
    USR
    X
    6 rows selected.
    SCOTT@orcl_11g> select * from files_included
      2  where  contains (filename, 'bin ls') > 0
      3  /
    PID              FILENAME
    123456-01        /usr/bin/ls/a
    123456-02        /usr/bin/ls/b
    SCOTT@orcl_11g> select * from files_included
      2  where  contains (filename, 'bin') > 0
      3  /
    PID              FILENAME
    123456-01        /usr/bin/ls/a
    123456-02        /usr/bin/ls/b
    123456-02        /usr/bin/x/b
    654321           /usr/bin/other
    SCOTT@orcl_11g> select * from files_included
      2  where  contains (filename, 'ls') > 0
      3  /
    PID              FILENAME
    123456-01        /usr/bin/ls/a
    123456-02        /usr/bin/ls/b
    123456-03        /usr/x/ls/a
    SCOTT@orcl_11g>

  • Document management system using oracle text

    i plan to create document management system using oracle text with following features
    1) document comparision
    2) document search
    and more...
    can oracle text be used to display documents of various formats by converting them to HTML. and can search keywords be highlighted in the document.
    please help!

    Have you ever considered doing this in Oracle Application Express (free on top of the Oracle database)? How about something like:
    http://download-west.oracle.com/docs/cd/B31036_01/doc/appdev.22/b28839/up_dn_files.htm
    Index the files using the CONTEXT index, and perhaps the docs' meta with it using the Oracle Text MULTI_COLUMN_DATASTORE, and then when you write your query for a report on the documents include a search string.
    I've created a number of APEX-based document management systems and it is quite easy once you get the hang of using this environment. I suggest looking at some of the tutorials/how-to documents and you'll be on your way quickly.
    Start with the upload application. Once you can get your documents in, create a report that shows everything except the document. Verify all of this works correctly.
    Add some "items" to the page for the report, and include them as bind variables in the where clause.
    After that, add your Oracle Text index to the database, and toss in a "text-field" item to the APEX page. Modify your report query, adding the CONTAINS clause, and use the newly created item as a bind variable. There's your keyword search.
    Linking to Oracle Apps is done through API's and may be over database links.
    Hope it helps. Though not a step-by-step how to document, this should point you in the right direction. Get familiar with APEX as that covers most of what you described.
    -Ron

  • How to use Oracle text

    I'm storing files in a blob field in a 9i database, sometimes I need to query using the details stored in the database about the file and sometimes I need to search the files to find matches with some text (like search engine), I was told that oracle text can help me accomplish this functionality , however I don't know if it supports arabic text and I don't know how to use it from my application developed in 9i.
    Regards.

    Friend by using these step you can easily use Oracle inter text media
    j a h a n z e b
    [email protected]
    Oracle Developer
    6th Floor, State Bank of Pakistan
    I.I.Chundrigar Road, Karachi.
    Please note that in SqlPlus you can use '?' in stead of $ORACLE_HOME, and this works on Unix and Windows so if you want to execute $ORACLE_HOME/rdbms/admin/catalog.sql you can simply use:
    on Unix sql> @?/rdbms/admin/catalog.sql
    on Windows sql> @?\rdbms\admin\catalog.sql
    5.2.1 Explanation of installation steps
    1. Connected to database as SYSDBA and create CTXSYS user:
    Ctxsys user is created by calling following script:
    @?/ctx/admin/dr0csys.sql <ctxsys> <system> <temp>
    Where:
    change_on_install - is the ctxsys user password
    DRSYS - is the default tablespace for ctxsys
    TEMP - is the temporary tablespace for ctxsys
    This will create user CTXSYS and grants full privileges to CTXSYS in order to create and insert into result tables, execute callbacks, rewrite queries, and perform system cleanup. At this point CTXSYS will not own any objects.ss
    2. Connected to database as CTXSYS and create all necessary objects
    All necessary object are creates by calling following script:
    connect CTXSYS/change_on_install
    @?/ctx/admin/dr0inst <replace with $ORACLE_HOME>/ctx/lib/libctxx9.so;
    Please not that you have to put full path to your ORACLE_HOME, for example home as paramter
    On Solaris/Aix/Linux with $ORACLE_HOME of /u01/app/oracle/product/8.1.7
    @?/ctx/admin/dr0inst.sql /u01/app/oracle/product/8.1.7/ctx/lib/libctxx8.so
    On HP-UX with $ORACLE_HOME of /u01/app/oracle/product/8.1.7
    @?/ctx/admin/dr0inst.sql /u01/app/oracle/product/8.1.7/ctx/lib/libctxx8.sl
    Windows NT/2000 with D:\oracle\product\8.1.7
    @?/ctx/admin/dr0inst.sql D:\oracle\product\8.1.7\bin\oractxx8.dll
    This will installs all Oracle database objects required by the Oracle Text system. This includes:
    a) Data dictionary tables, views, sequence, packages
    b) Server management tables, views and packages
    c) Dispatcher packages
    d) Service queue objects
    3) Install appropriate language-specific default preferences.
    The next step is to install appropriate language-specific default preferences.When you use CREATE INDEX to create an index or ALTER INDEX to manage an index, you can optionally specify indexing preferences in the parameter string. There are seven preference classes:
    - Lexer, defines the language being indexed. ( language specific )
    - Wordlist, defines the expantion of stem and fuzzy queries. ( language specific )
    - Stoplist, defines words and themes that are not be indexed. ( language specific )
    - Datastore, defines document storage.
    - Filter, defines standards for converion of documents to plaintext.
    - Storage, defines the storage of the index tables.
    - Section group, enables possibilities to define document sections.
    There is script which creates language-specific default preferences for every language Oracle text supports in <ORACLE_HOME>/ctx/admin/defaults directory, such as English(US), Danish(DK), Dutch(NL), Finnish(SF), French(FR), German(DE), Italian(IT), Portuguese(PR), Spanish(ES), and Swedish(S). They are named in the form drdefXX.sql, where XX is the language code. To manually install US default preferences, for example, log into sqlplus as CTXSYS, and run 'drdefus.sql' as described below:
    @?/ctx/admin/defaults/drdefus.sql
    create user textuser identified by textuser
    default tablespace users
    temporary tablespace temp;
    -- You must grant 'ctxapp' role to textuser
    grant connect, resource, ctxapp to textuser;
    connect textuser/textuser
    drop table quick;
    create table quick (
    quick_id number
    constraint quick_pk primary key,
    text varchar2(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 jumps over the lazy dog' );
    insert into quick ( quick_id, text ) values (3,'The dog barked like a dog');
    commit;
    create index quick_text on quick ( text )
    indextype is ctxsys.context;
    col text format a45
    col s format 999
    select text, score(42) s from quick
    where contains ( text, 'dog', 42 ) > 0
    order by s desc;

  • SQL Injection with Oracle Text

    I did a search here for any posts about SQL Injection on Oracle Text indexes, but returned no hits.
    Can anyone give their opinion about whether SQL Injection is a concern when using Oracle Text or what steps can be taken ahead of time to prevent (or at least reduce the attack surface) on Oracle Text queries.
    We're running a web app. that will use Oracle Text and our users can enter any search string as well as select pre-defined items from a drop down box.
    Thanks in advance for any opinions
    LJ

    quote:
    Originally posted by:
    Dan Bracuk
    What others can do is more relevent than what we think. When
    in doubt, test.
    very true, although my final solution went more like, "When
    in doubt, manually add about 600 cfqueryparams in 406 cfquery
    tags".

  • Oracle Text performance -- failed attempts

    We are trying to implement a simple search of text data stored in a heavily used table (inserts/updates). There are 3 columns to index --
    Headline (varchar2(255))
    Subheadline (varchar2(255))
    Teaser (varchar2(4000))
    The first attempt to implement Oracle text w/ CATSEARCH
    begin
    ctx_ddl.create_index_set('cms_iset');
    ctx_ddl.add_index('cms_iset','poolid_cp, mediaid_cp'); /* sub-index A */
    end;
    ---- We knew we were going to filter on poolid_cp and mediaid_cp ---
    CREATE INDEX cms_headlineidx ON con_properties (headline)
    INDEXTYPE IS ctxsys.CTXCAT
    PARAMETERS ('index set cms_iset');
    CREATE INDEX cms_subheadlineidx ON con_properties (subheadline)
    INDEXTYPE IS ctxsys.CTXCAT
    PARAMETERS ('index set cms_iset');
    CREATE INDEX cms_teaseridx ON con_properties (teaser)
    INDEXTYPE IS ctxsys.CTXCAT
    PARAMETERS ('index set cms_iset');
    *********THE RESULTS*************
    Our application server would spin up threads that would appear to be hanging. The load on the DB servers (RAC) were higher than normal. This implementation would have saved on having to do resync's manually.
    The next attempt was implementing w/ CONTEXT:
    alter table con_properties add (dummy varchar2(1));
    begin
    ctx_ddl.create_preference('con_propsearch', 'MULTI_COLUMN_DATASTORE');
    ctx_ddl.set_attribute('con_propsearch', 'columns', 'headline,subheadline,teaser');
    end;
    CREATE INDEX con_properties_searchidx
    ON con_properties(dummy)
    INDEXTYPE IS CTXSYS.CONTEXT
    PARAMETERS ('datastore CTXSYS.con_propsearch')
    Records getting put into the ctx_user_pending table a few hundred per hour.
    ********THE RESULTS*************
    Same issue with the application servers spinning off threads that seem to be hung. Spikey load on the DB servers (RAC).
    NOTE: In both implementations, running search querys ran OK. However, dropping the text index in BOTH cases caused the application servers to behave normally.
    Can anyone tell me what's going on internally with Oracle TEXT when a table is heavily inserted and updated? What is going on in the background. Is there some sort of lock that the app servers are waiting on? I know there is "overhead" with inserts on a normal b-tree index. Is it "exponential" with Oracle Text?
    Thank you!

    When documents in the base table are inserted, updated, or deleted, their ROWIDs are held in a DML queue until you synchronize the index. You can view this queue with the CTX_USER_PENDING view. Apparently, you are not synchronizing your context index, so the queue is building infinitely. You need to establish some method of synchronizing your index. You can use parameters('sync(on commit)') in your index creation or create an after insert or update statement level trigger, not row trigger, that uses dbms_job.submit to schedule ctx_ddl.sync_index to synchronize the index upon commit of the dml or you can manually run ctx_ddl.sync_index periodically or schedule it or you can alter and rebuild your index periodically or you can drop and recreate it periodically. Which method you choose depends on how current the information that you query needs to be. If your data needs to be current up to the moment, the you should sync on commit. Otherwise it may be better to do it in periodic batches.

  • Oracle Text Web Search

    Can someone point me to some tutorials for a simple web search app using oracle text?
    Thanks in advance,
    New-B

    Check the Oracle Text Application Developers Guide Appendix for an example. The guide is available from tahiti.oracle.com

  • Oracle Text with eBusiness Suite

    I'm trying to understand if Oracle eBusiness Suite uses Oracle Text for indexing certain queries such as item description, etc.. I was told that iStore uses it for searching on items. Is that true? Does the Oracle Apps standard Item form use it? Can it be set up for use with the apps? I know the query syntax is different (CONTAINS), and I don't see any non standard indexes on MTL_SYSTEM_ITEMS_B, so I'm not sure how I could implement the functionality in the apps. Please help!!!!

    Yes, Oracle Text is used in iStore Search Feature, Refer to code under $JAVA_TOP/oracle/apps/ibe/catalog/Search.java for an example, also look at table ibe_ct_imedia_search table and its indexes which gives an idea of how Oracle iStore is leveraging Oracle Test for Searching.
    get the data into a staging table and then create whichever index you want, dont modify the indexes on key tables like MTL_SYSTEM_ITEMS_B

  • Reinstalling/Repairing Oracle Text in Oracle 11g R2

    I happened to execute 'create or replace operator contains...' How do I restore Oracle Text to its previous state?
    Edited by: 932881 on May 9, 2012 1:05 AM

    Having run '/u01/app/oracle/product/11.2.0/db_1/ctx/admin/catctx.sql CTXSYS SYSAUX TEMP NOLOCK', I tried to create a CTXSYS.CONTEXT index on a VARCHAR2 column but I got this error:
    Error at Command Line:1 Column:26
    Error report:
    SQL Error: 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 366
    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.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • How do I install ORACLE TEXT

    I have an Oracle installation (win64_11gR1_database_111070.zip) on a Windows Server 2008 x64.
    I am trying to restore a dmp file to the new oracle installation. The dump file was created using Oracle Ent. 8.1.7.
    When restoring the dump file everything is working fine until the VIEW tables need to be created.
    I get this error message:
    ORA-20000: Oracle Text error:
    DRG-11422: linguistic initialization failed
    DRG-11446: supplied knowledge base file C:\app\Administrator\product\11.1.0\db_1\ctx\data\enlx\droldUS.dat not installed
    Searching online I need to install the ORACLE TEXT. However, I am not able to find it anywhere. It supposed to come on the companion cd, but I just can't find it anywhere.
    Can someone just give me a direct link to download it.
    Thank You in advance.

    Ok. I belevie that I am really close.
    I found this link: http://www.oracle.com/technology/software/products/database/oracle11g/111060_win64soft.html
    which has:
    Oracle Database 11G Examples (formerly Companion)
    win64_11gR1_examples.zip
    I am new at all of this, specially at ORACLE TEXT. I still don't understand how it works, so any detailed help would be greatly appreciated.
    Thank You.
    Edited by: correiasim on Sep 29, 2009 8:32 AM

Maybe you are looking for

  • "Unable to Access" error msg for BI Publisher Report

    Hello All, I am getting the following error when trying to access a BI Publisher report from the dashbaord. We can access the folders that come with BI Publisher examples, ie Executives, Financials, HR Manager but not the "GTR" that we have created.

  • Few questions about Earthing?

    Hi all, I have some basic questions about earthing. Please anyone explain them and provide any reference material also. Q1. In Industries there are normally two types of earth, one is "Instrument Earth" and other is "Protective Earth". what is the di

  • Smart folders and multiple email addresses

    My wife uses multiple email addresses.  I've tried to set up a smart folder in my mail that would allow me to put multliple conditions that would allow me to have one smart folder that collects emails from her multiple accounts. The problem I hsve is

  • What is the irpt file

    can anybody help me that what is irpt file

  • Update AD values

    Hello, We are trying to loop through a recordset to update AD values that have changed.  If the value for a particular property in AD already exists (ie middle initial) then updating that value to another works great.  The problem arrises that when t