Searching for words with dot  in the context index.

Hi ,
We have a context index that uses a following BASIC_LEXER
drop_preference (c_lexer_pref);
ctx_ddl.create_preference(c_lexer_pref, 'basic_lexer');
ctx_ddl.set_attribute(c_lexer_pref, 'base_letter', 'YES');
ctx_ddl.set_attribute(c_lexer_pref, 'whitespace', '()"`/');
ctx_ddl.set_attribute (c_lexer_pref, 'index_stems', 'english');
When user searches for "OAR" , oracle does not find "O.A.R'"
Can someone help me understand why oracle is not able to find the "O.A.R" when OAR is being searched.
Thanks for your help.

You need to use skipjoins to tell it to skip the periods, as shown below.
scott@ORA92> drop table your_table
2 /
Table dropped.
scott@ORA92> exec ctx_ddl.drop_preference ('c_lexer_pref')
PL/SQL procedure successfully completed.
scott@ORA92> begin
2 ctx_ddl.create_preference ('c_lexer_pref', 'basic_lexer');
3 ctx_ddl.set_attribute ('c_lexer_pref', 'base_letter', 'YES');
4 ctx_ddl.set_attribute ('c_lexer_pref', 'whitespace', '()"`/');
5 ctx_ddl.set_attribute ('c_lexer_pref', 'index_stems', 'english');
6 ctx_ddl.set_attribute ('c_lexer_pref', 'skipjoins', '.');
7 end;
8 /
PL/SQL procedure successfully completed.
scott@ORA92> create table your_table
2 (your_column varchar2(30))
3 /
Table created.
scott@ORA92> insert into your_table values ('OAR')
2 /
1 row created.
scott@ORA92> insert into your_table values ('O.A.R')
2 /
1 row created.
scott@ORA92> create index your_index
2 on your_table (your_column)
3 indextype is ctxsys.context
4 parameters ('lexer c_lexer_pref')
5 /
Index created.
scott@ORA92> select * from your_table
2 where contains (your_column, 'OAR') > 0
3 /
YOUR_COLUMN
O.A.R
OAR
scott@ORA92>

Similar Messages

  • PDF Search: Escape chars / search for words containing dots

    Hello,
    i'm trying to do a search for ip adresses in a pdf document - eg for "10.100.0.1" - but it seems that adobe reader doesnt cope with the included dots.
    Is there a way to search for words containing dots? Maybe some way of escaping the dot?
    Thanks,
    Moritz

    Reader can find dots just fine. There's probably something going on with your file, like font issues or spaces between the text, or something like that.

  • HT204389 any news about when you will be able to search for businesses with siri in the uk?

    any news about when you will be able to search for businesses with siri in the uk?

    Welcome to Apple forums
    We don't know when Apple will implement this in Siri, so wait at least to iOS 6

  • Need to search for words with similar meaning

    HI,
    I want to search for words which are similar in meaning,
    for example, search with the keyword LIME should give LIME , LEMON etc.
    Can it be done using the inbuilt thesaurus?

    I don't know how similar the example that you provided is to your actual problem.  Synonyms are not the only relations that you can set.  You an also use related terms and hierarchies using broader and narrower terms.  In the following example, I have created citrus as a broader term and created lemon, lime, and orange as narrower terms underneath citrus.  I have them demonstrated how you can query to return all items from the same category that lemon is in, by first finding the broader term citrus above it, then searching for all narrower terms underneath that.  I have included some intermediary results that you don't need to run, just for better understanding of how the query is formed.
    SCOTT@orcl12c> create table test_tab
      2    (test_col  varchar2(60))
      3  /
    Table created.
    SCOTT@orcl12c> insert all
      2  into test_tab values ('lemon')
      3  into test_tab values ('lime')
      4  into test_tab values ('orange')
      5  into test_tab values ('toaster oven')
      6  select * from dual
      7  /
    4 rows created.
    SCOTT@orcl12c> create index test_tab_idx on test_tab (test_col) indextype is ctxsys.context
      2  /
    Index created.
    SCOTT@orcl12c> begin
      2    ctx_thes.create_thesaurus ('test_thes');
      3    ctx_thes.create_relation ('test_thes', 'lemon', 'bt', 'citrus');
      4    ctx_thes.create_relation ('test_thes', 'lime', 'bt', 'citrus');
      5    ctx_thes.create_relation ('test_thes', 'orange', 'bt', 'citrus');
      6  end;
      7  /
    PL/SQL procedure successfully completed.
    SCOTT@orcl12c> variable g_search varchar2(100)
    SCOTT@orcl12c> exec :g_search := 'lemon'
    PL/SQL procedure successfully completed.
    SCOTT@orcl12c> select ctx_thes.bt (:g_search, 1, 'test_thes') from dual
      2  /
    CTX_THES.BT(:G_SEARCH,1,'TEST_THES')
    {LEMON}|{CITRUS}
    1 row selected.
    SCOTT@orcl12c> select 'nt(' ||
      2            replace (ctx_thes.bt (:g_search, 1, 'test_thes'), '|', ', 1, test_thes)|nt(')
      3            || ', 1, test_thes)'
      4  from  dual
      5  /
    'NT('||REPLACE(CTX_THES.BT(:G_SEARCH,1,'TEST_THES'),'|',',1,TEST_THES)|NT(')||',
    nt({LEMON}, 1, test_thes)|nt({CITRUS}, 1, test_thes)
    1 row selected.
    SCOTT@orcl12c> select * from test_tab
      2  where  contains
      3            (test_col,
      4            'nt(' ||
      5            replace (ctx_thes.bt (:g_search, 1, 'test_thes'), '|', ', 1, test_thes)|nt(')
      6            || ', 1, test_thes)') > 0
      7  /
    TEST_COL
    lemon
    lime
    orange
    3 rows selected.

  • CONTAINS and searching for words with an apostrophe

    I have a CONTEXT index in place, and I'm trying to search for the word
    JOHN'SHow do you go about going that, I tried both
    JOHN'S
    JOHNSand neither worked.
    --=Chuck

    How are you doing your search?
    SQL> create table test1 (
      2  a1 number,
      3  a2 varchar2(20));
    Table created.
    SQL> insert into test1 select level, 'Line '||level from dual connect by level < 500;
    499 rows created.
    SQL> insert into test1 values (1000, 'JOHN''S');
    1 row created.
    SQL> create index context_index on test1 (a2) indextype is ctxsys.context;
    Index created.
    SQL> select * from test1
      2  where contains (a2, 'JOHN''S') > 0;
            A1 A2
          1000 JOHN'S
    SQL> select * from test1
      2  where contains (a2, 'JOHNS') > 0;
    no rows selected
    SQL> select * from test1
      2  where contains (a2, 'JOHN') > 0;
            A1 A2
          1000 JOHN'S

  • I have an apple iphone 4gs... It is synced with my outlook exchange in the office. If I do a search for emails that also checks the server then all of a sudden I end up with various amounts unread email with the inbox saying "Inbox 71" ..which is not true

    I have an apple iphone 4gs... It is synced with my outlook exchange in the office. If I do a search for emails that also checks the server then all of a sudden I end up with various amounts unread email with the inbox saying "Inbox 71" ..which is not true. The only way to make the inbox on the iphone back to 0 is to delete the account then re install it.
    Anyone have any ideas

    We need to know more about your system, please download EtreCheck and run the report and please post it on your next reply. Then we can see how your system is configured, what apps are on it and look for anything obvious. We will look forward to seeing your report.

  • TS4611 I have just received my second MacBook Air 11" the Wifi connection keeps dropping. Also after 3 meters away it keeps searching for network! It is the second try and the same issue. Will Apple ever come up with a solution?

    I have just received my second MacBook Air 11" the Wifi connection keeps dropping. Also, after 3 meters away from the rooter it keeps searching for network! It is the second try and the same issues. Will Apple ever come up with a solution? There is a program pack for the connection issue but I cannot believe that this computer wifi keeps connected only while nearby the rooter!

    Applied this update?
    http://support.apple.com/kb/TS4611?viewlocale=en_US&locale=en_US
    If the update is installed aready, you may have to wait until OS X 10.8.5
    update if and when it is relased.
    Best.

  • Can't search for words anymore after saving PDFs in Preview

    Hi everyone,
    I would love to use Preview for my day-to-day use of previewing PDFs + highlighting + setting annotations. However, once I have saved the pdf with Preview I can not search for words anymore. If I search for one letter only, I would get cryptic hits like "7;%! 2%8%P%8!".
    I am not sure, but I guess when preview saves the pdf using a Quartz PDF context, something happens with the index, or the underlying the font structuring.
    Does anyone have had experience with these kinds of troubles?
    Thanks in advance,
    Heinrich

    Hi, thanks for answering quickly, and the heads up on that other thread.
    It undoubtedly has to do with the annotations or mark ups (the last, in my case).
    In the linked-to thread they end by suggesting that it's because it's has "commenting not allowed" when you see it
    using Adobe Reader, File > Properties > Security says Commenting: Not Allowed.
    However, some documents with "commenting not allowed set in Adobe Reader I can highlight or annotate fine, without it messing up after saving.
    Besides, any document I save as pdf even from Word, will say commenting not allowed in Adobe Reader. So if even my own documents are not highlight- or annotate-able without garbling the text, what documents would these functions be for, then?
    I think what somebody mentioned in the other thread about character encodings hold some truth, I see it in documents in Danish with æ ø and å (however, not all!), but not in English-only docs (yet. Have any of you?).
    Thanks in advance,
    - Alexander

  • Unable to search for words in a pdf document

    I am using Adobe Reader Ver 10.1.1 (All updates)
    I have a pdf document in which I am unable to search for words. No words in the document are found even though they do exist. If I copy a word from within the document and paste it into the search criteria then instead of getting the word that I copied, I get substitute characters and it can in fact find these characters as the word being searched.
    The document is a catalog and can be downloaded from the following URL.
    http://www.carbatec.com.au/getcatalogue?zenid=d1cuvbat0ois0g37r0r33vnah1
    I will appreciate any help as to why I cannot search for words in the document.

    Thank you Dave Merchant and try67 for your responses. As per my previous post, I contacted the company re the catalogue and they have responded favourably. I'll include their response because it gives the reason for the search failure as document compression which you might find interesting. I'll await their new catalogue and see if they have fixed the problem.
    Company response:
    Thank you very much for your input.  And yes, you are correct, the compression we used for the current catalogue's PDF format does strip out text included in the catalogue.  We used the compression settings we did with the intention of minimising download time, however I take your point about including text for search purposes (which I also utilise when I'm scanning through PDFs).
    We will actually be posting out our new catalogue next week and we'll release the new PDF version on the website at the same time.  I've asked our graphic designer to ensure that the PDF we use for the new catalogue includes searchable text.

  • I need autocomplete  for search for words in a txt. file

    i am not so good in java.
    I have a running code for search in text with a txt. file (from user bluefox815).
    But I need a solution with autocomplete for search for words in a txt. file.
    test_file.txt (Teil des Inhaltes):
    Roboter robots
    Mechatronik mechatronics
    and so on
    Can you help me please.
    Here is the code:
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    import java.io.*;
    * this program searches for a string in a text file and
    * says which line it found the string on
    public class SearchText implements ActionListener {
    private String filename = "test_file.txt";
    private JFrame frame;
    private JTextField searchField;
    private JButton searchButton;
    private JLabel lineLabel;
    private String searchFor;
    private BufferedReader in;
    public SearchText() {
    frame = new JFrame("SearchText");
    frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    searchField = new JTextField(80);
    searchButton = new JButton("Search");
    // this is used later in our actionPerformed method
    searchButton.setActionCommand("search");
    // this sets the action listener for searchButton, which is the current class
    // because this class implements ActionListener
    searchButton.addActionListener(this);
    lineLabel = new JLabel("nach dem Fachbegriff suchen");
    public void createGUI() {
    JPanel topPanel = new JPanel();
    topPanel.setLayout(new BoxLayout(topPanel, BoxLayout.X_AXIS));
    JPanel bottomPanel = new JPanel();
    JPanel mainPanel = new JPanel();
    mainPanel.setLayout(new BoxLayout(mainPanel, BoxLayout.Y_AXIS));
    topPanel.add(searchField);
    topPanel.add(searchButton);
    bottomPanel.add(lineLabel);
    mainPanel.add(topPanel);
    mainPanel.add(bottomPanel);
    frame.getContentPane().add(mainPanel);
    frame.pack();
    frame.setVisible(true);
    public void actionPerformed(ActionEvent e) {
    // now we get the action command and if it is search, then it is the button
    if ("search".equals(e.getActionCommand())) {
    searchFor = searchField.getText();
    searchTheText();
    private void searchTheText() {
    // I initialize the buffered reader here so that every time the user searches
    // then the reader will start at the beginning, instead of where it left off last time
    try {
    in = new BufferedReader(new FileReader(new File(filename)));
    } catch (IOException e) {
    String lineContent = null;
    int currentLine = 0;
    // this will be set to true if the string was found
    boolean foundString = false;
    while (true) {
    currentLine++;
    // get a line of text from the file
    try {
    lineContent = in.readLine();
    } catch (IOException e) {
    break;
    // checks to see if the file ended (in.readLine() returns null if the end is reached)
    if (lineContent == null) {
    break;
    if (lineContent.indexOf(searchFor) == -1) {
    continue;
    } else {
    lineLabel.setText(String.valueOf(lineContent));
    foundString = true;
    break;
    if (!foundString)
    lineLabel.setText("Es kann kein Fachbegriff gefunden werden.");
    try {
    in.close();
    } catch (IOException ioe) {
    public static void main(String[] args) {
    SwingUtilities.invokeLater(new Runnable() {
    public void run() {
    new SearchText().createGUI();
    }

    Markus1 wrote:
    But I need a solution with autocomplete for search for words in a txt. file.What is your question? What have you tried so far? What are you having difficulty with?
    Mel

  • Searching for words in Album names

    My iPhoto search function is unable to find words that are in the names of newly-created Albums. It can find words in the names of albums I created some time back but not in new one.
    This is what I do:
    1) Select several photos.
    2) Push the plus sign to create a new album.
    3) Give the album a unique name like "dazzler"
    4) Select the tab to view all photos in the library.
    6) Do a search for "dazzler", but nothing comes up.
    Very strange.
    If I search for words in libraries I created a week ago, they show up fine.
    I've already reindexed Spotlight, restarted, and tried various other general things, all to no avail. Any advice would be appreciated.
    Thanks,
    Matthew

    I can confirm your problem. Report the bug at http://www.apple.com/feedback/iphoto.html as will I.
    TIP: For insurance against the iPhoto database corruption that many users have experienced I recommend making a backup copy of the Library6.iPhoto (iPhoto.Library for iPhoto 5 and earlier) database file and keep it current. If problems crop up where iPhoto suddenly can't see any photos or thinks there are no photos in the library, replacing the working Library6.iPhoto file with the backup will often get the library back. By keeping it current I mean backup after each import and/or any serious editing or work on books, slideshows, calendars, cards, etc. That insures that if a problem pops up and you do need to replace the database file, you'll retain all those efforts. It doesn't take long to make the backup and it's good insurance.
    I've created an Automator workflow application (requires Tiger), iPhoto dB File Backup, that will copy the selected Library6.iPhoto file from your iPhoto Library folder to the Pictures folder, replacing any previous version of it. It's compatible with iPhoto 6 and 7 libraries and Tiger and Leopard. iPhoto does not have to be closed to run the application, just idle. You can download it at Toad's Cellar. Be sure to read the Read Me pdf file.

  • Search for word/phrase by ctrl+shift+F

    ctrl+shift+F
    One can enter here  the file/folder path the search for word/phrase should be made.
    But length of this control element is really limited.
    If the chosen path is very long, with lot of folder levels, longer than the control element is capable to show it,
    the path string is truncated. Truncation in its middle part.
    Nobody is able to see how exactly the path is, after it has been shortened.
    And now, please imagine that there are several similar paths on the disc.
    They differ by theirs middle section only.
    Now assume the search needs 3 hours.
    1. After 3 hours of search run user can't say which folder of all similar folders he has chosen for last search operation.
    After search completes user is no able to check, which path the search ran in.
    2. If new search in some other folder but in a folder located close to the previous one is aimed  the user
    has to follow the whole path from the disc root - job intensive task.
    Adobe Reader should use the previous search path as start point of new search path selection.
    The full-feature product Adobe Acrobat probably also affected.

    Hi vmartin01,
    I tried to check at my end and it works fine at my end.
    Regards,
    Ajlan Huda.

  • Generating RoboHelp for Word with RH6 in HTML Doesn't Remove MSO styles

    Here's the Word portion of the question, which I really
    should post under a separate heading. (The WebHelp portion is under
    WebHelp - DiMost, posted March 19, 2007)
    In RHx5, I use(d) RoboHelp for Word to convert my documents
    from an Information Mapping format (with tables) to a stripped-down
    document that I converted to HTML without all the Word inline
    styles.
    - Applied a "conversion" template to the doc
    - Imported the doc into the RH for Word file.
    - Converted the styles and removed page breaks
    - Converted ONE heading to the main topic
    - Created WinHelp and checked to be sure there are no
    corrupted tables and the topic converted
    - Generated in WebHelp
    - Imported the HTML document output to the main WebHelp
    project. (The document arrives without all the MSO word inline
    styles)
    - Applied the CSS for the project.
    Document conversion complete....all the inline styles were
    removed.
    NOW, RH 6 retains all the styles and converts every heading
    style to a topic, even though RH5 did not.
    Converting it in RoboHelp for Word x5 worked really well, but
    doesn't appear to work now. And importing the Word doc directly
    into RH6 for the WebHelp project is still the huge mess it was
    before. It looks like it still requires hand-stripping all that
    code out by hand.
    Believe me, I have tried everything (including freestanding
    apps) to get rid of the Word (MSO-whatever) embedded styles out of
    the Word HTML.
    I welcome any ideas. Thanks!
    Diana

    I don't think anything changed on defining what should be a
    new topic. Check the options as you import as that can make such a
    difference and of course your RH6 settings will be different
    initially.

  • Do you know a reader app in which I can search for words?

    Do you know a reader app in which I can search for words? I mean which can open .doc files and i can search for specific words in the full text! Thanks!

    I am not aware of any such fix.  If you are concerned, apply a screen protector.

  • For FF19 with PDFs, can the yellow "Open With Different Viewer" pop-up bar be disabled?

    Hi all, I really like the built in PDF viewer because search as a I type works with, thanks FF devs!
    But ... I get this yellow pop-up with many PDFs I view:
    This PDF document might not be displayed correctly and a button for Open With Different Viewer
    The thing is these PDFs seem fine and I have to close the warning every time.
    Is there anyway this pop-up can be disabled or I can set an about:config setting to skip it? I can manually save a PDF or disable FF19's viewer if there's a noticeable problem with the FF19 viewer.

    Ok, since the pop up bar can't be disabled I'll disable the built in PDF viewer. Too bad, I like the search as you type feature with PDFs but this un-disable-able pop-up bar is not user friendly.

Maybe you are looking for

  • Lightroom won't ask how to edit a file when I select "edit in Photoshop CS6"

    Yesterday Lightroom suddenly stopped asking how I want the file edited when I select "edit in Photoshop".  I opens the file directly in Photoshop without asking do I want to "edit with Lightroom changes", "edit a copy", or "edit original". I've tried

  • How to add a system font without image render

    Please take a look at www.jumsoft.com website at the left bottom footer of their page. The text "Latest Tweets" is selectable . How can I use this kind of font with muse? Also how can I add a shadow effect to text as this website does it? Thank you

  • Export Index from PDF Portfolio

    I need to compare two large PDF Portfolio documents. From what I can tell, there is currently no third party software around that will do this so I'm trying to figure out a way around it. Each Portfolio that I'm working with has over a thousand email

  • How to 'save target as' from java?

    pardon for the english and pardon if the post is not in the right place. the idea to open a webpage (url given) that contains links to several pdf files, and to save those files in the hard disk. how can this be done with java? can anybody help?

  • Defaulting the Out put type in out put

    Hi All, I have an issue in output- I am having two out put types say AA00 & BB00 for say order confirmation and order acknowledgement. When I am issuing out put for print I am getting both the condition option but not able to select? I want to make t