Problem solve Get help with specific problems with your technologies, process and projects.

Doing a keyword search within contents of memo field

Would you be kind enough to inform me of a way to do a keyword search inside the contents of a memo field in an Oracle database?

If you are just searching for a specific word in a column, then you can use the '%' wildcard, which standards for any number of characters, similar to the '*' wildcard for DOS or Unix filenames. So to search COL_A from TABLE_A for those rows which contain the word "apache", you would use a query similar to the following:

SELECT * FROM table_a WHERE col_a LIKE '%apache%';
The LIKE operator will search for those columns that are "like" the given phrase, taking into account any wildcards. The '_' wildcard matches one and only one character, similar to the '?' DOS wildcard for filenames. If you are looking into more sophisticated indexes and searching of data, you might want to investigate the ConText option, now called Oracle interMedia. This is an add-on option though.

For More Information

Dig Deeper on Oracle database design and architecture

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.