July 26, 2012 at 12:53 am
Hi All,
I have to serach for a word from a table . I have used containstable() function , but not getting expected results.
Can you please trace the below query is there any change is required.
SELECT cal.log_id , cal.cas_details
FROM es.g_case_action_log cal (READUNCOMMITTED)
INNER JOIN g_case c (READUNCOMMITTED) ON (cal.case_id = c.case_id)
INNER JOIN containstable(es.g_case_action_log, cas_details,
' "searchword" OR "
searchword" OR "searchword
" ') AS key_tbl
ON cal.log_id = key_tbl.
Please help..
With Regards
Krishna
July 26, 2012 at 1:15 am
krishna.netblogs (7/26/2012)
Hi All,I have to serach for a word from a table . I have used containstable() function , but not getting expected results.
Can you please trace the below query is there any change is required.
SELECT cal.log_id , cal.cas_details
FROM es.g_case_action_log cal (READUNCOMMITTED)
INNER JOIN g_case c (READUNCOMMITTED) ON (cal.case_id = c.case_id)
INNER JOIN containstable(es.g_case_action_log, cas_details,
' "searchword" OR "
searchword" OR "searchword
" ') AS key_tbl
ON cal.log_id = key_tbl.
Please help..
With Regards
Krishna
Hello and welcome to SSC!
I'm afraid that you haven't really given us enough to go on there. Remember, we can't see your data, your expected results or your actual results. So without a reproducible script that shows your problem, there isn't much that anyone can do to help you.
If you could set-up DDL and sample data scripts that reproduce the issue that you're experiencing, then I'm sure someone will be able to offer advice.
For now, can I just point out that NOLOCK (or READUNCOMMITTED) is not a magic go faster pill. It has serious side effects that affect the integrity of your queries. Have a read through these articles for more information: -
Or do a search in your favourite search engine for side effects to NOLOCK.
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply