Home » Server Options » Text & interMedia » Find Words in a String (11g Release 2 Windows)
Find Words in a String [message #618415] Fri, 11 July 2014 10:15 Go to previous message
Duane
Messages: 557
Registered: December 2002
Senior Member
Anyone have a query that can find WORDS in a String and break out those words?

User types in "George Washington" into an input field and that string is passed to an Oracle procedure where the words are split out.

It's also possible that a user could type in "George Washington DC" so it's not always limited to just 2 words.


Input_String = 'George Washington';

procedure XYZ (Input_String  in  varchar2,
               Results       out sys_refcursor)


begin

open Results for 
  select column1,
         column2,
         column3,
         .
         .
         column20
    from presidents_table
      where first_name = WORD1 or
            last_name  = WORD2

end

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Is there a way to customize the BASE_LETTER conversions that oracle text does
Next Topic: extract information from an unstructured email into tables
Goto Forum:
  


Current Time: Thu Mar 28 05:25:03 CDT 2024