Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Use like clause more then once

Use like clause more then once

From: Jeremy Smith <godtoall_at_hotmail.com>
Date: 29 May 2007 08:45:03 -0700
Message-ID: <1180453503.771429.212600@h2g2000hsg.googlegroups.com>


Trying to lower the cost of the query below, do to the large disk read for the table services.

SELECT SERVER_ID,SERVER_NAME
  FROM serverdb.servers
 WHERE status_id = 1
   AND server_id IN (SELECT server_id

                       FROM services
                      WHERE svc_display_name LIKE '%Microsoft Exchange
%')

   AND server_id IN (SELECT server_id

                       FROM services
                      WHERE svc_display_name LIKE '%TSM%')

I thought about doing a text index on the column svc_display_name and updating the query to do a contain, but this table has a lot of delete, insert and updates. So I wasn't sure how creating a text index would slow down all of the transactions on the table services.

My goal is to do a search on the services table only once and not 2 times.

Any thoughts would be helpful! thanks Received on Tue May 29 2007 - 10:45:03 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US