August 12, 2009 at 4:18 pm
Hi all,
I am trying to return the specific block of XML where the @SearchTerm phrase was found. I was trying to use the query() and contains() methods to get the specific block where the phrase was found.
here my query.
DECLARE @SearchTerm varchar(3000) = 'Availability through Health Insurance Exchange'
DECLARE @SearchTerm2 varchar(3000) = '"Availability through Health Insurance Exchange"'
SELECT
BillText.query('contains(.,sql:variable("@SearchTerm"))')
,*
FROM
Legislative.BillText bt
INNER JOIN CONTAINSTABLE (Legislative.BillText,BillText,@SearchTerm2) as k
ON k.[Key] = bt.BillTextID
What am I missing?
Thanks
Brian W
August 13, 2009 at 12:44 am
You are mixing both XML (xquery) and FULLTEXT?
N 56°04'39.16"
E 12°55'05.25"
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy