+ Reply to Thread
Page 1 of 5 1 2 3 ... LastLast
Posts 1 to 10 of 48
  1. #1

    Potty-trained

    suityou01's Avatar
    Join Date
    Jan 2009
    Location
    Skid row
    Posts
    20,965
    Thanks (Given)
    177
    Thanks (Received)
    208
    Likes (Given)
    742
    Likes (Received)
    713

    Default FullText Search - SQL Server

    Hello, can you help me as I am too stupid to figure this out for myself.

    I want to enable FullText search on a Text column. I have added a FullText catalog, and added the column to the catalog and populated the index.
    The FullText search service is running.

    However I get no hits. I should point out that StopWords is off.

    Soooo

    If my column contains 'Attrn' and I search on CONTAINS (MyColumn,'Att') I would expect to get a hit, but I don't.

    Are there any other bear traps I haven't considered?
    Embrace your inner weird.

  2. #2

    Godlike


    Join Date
    Sep 2014
    Location
    Non-Event Horizon
    Posts
    8,676
    Thanks (Given)
    332
    Thanks (Received)
    586
    Likes (Given)
    2208
    Likes (Received)
    2628

    Default

    Have you tried using FREETEXT instead of CONTAINS?
    The greatest trick the devil ever pulled was convincing the world that he didn't exist

  3. #3

    Double Godlike!


    Join Date
    Dec 2012
    Posts
    10,224
    Thanks (Given)
    728
    Thanks (Received)
    710
    Likes (Given)
    4820
    Likes (Received)
    2796

    Default

    You mean apart from the fact that code is wrong......

    How do you get leading wildcard full-text searches to work in SQL Server? - Stack Overflow

    My invoice is in the post

  4. #4

    Potty-trained

    suityou01's Avatar
    Join Date
    Jan 2009
    Location
    Skid row
    Posts
    20,965
    Thanks (Given)
    177
    Thanks (Received)
    208
    Likes (Given)
    742
    Likes (Received)
    713

    Default

    Quote Originally Posted by MrMarkyMark View Post
    You mean apart from the fact that code is wrong......

    How do you get leading wildcard full-text searches to work in SQL Server? - Stack Overflow

    My invoice is in the post
    You lost me. How is my code wrong?
    Embrace your inner weird.

  5. #5

    Double Godlike!


    Join Date
    Dec 2012
    Posts
    10,224
    Thanks (Given)
    728
    Thanks (Received)
    710
    Likes (Given)
    4820
    Likes (Received)
    2796

    Default

    Quote Originally Posted by suityou01 View Post
    You lost me. How is my code wrong?
    No Wildcard

  6. #6

    Potty-trained

    suityou01's Avatar
    Join Date
    Jan 2009
    Location
    Skid row
    Posts
    20,965
    Thanks (Given)
    177
    Thanks (Received)
    208
    Likes (Given)
    742
    Likes (Received)
    713

    Default

    Quote Originally Posted by LondonManc View Post
    Have you tried using FREETEXT instead of CONTAINS?
    Thanks LM. I just tried that. Still nothing.

    Like 'attn%' does work
    Embrace your inner weird.

  7. #7

    Godlike


    Join Date
    Sep 2014
    Location
    Non-Event Horizon
    Posts
    8,676
    Thanks (Given)
    332
    Thanks (Received)
    586
    Likes (Given)
    2208
    Likes (Received)
    2628

    Default

    Quote Originally Posted by suityou01 View Post
    Thanks LM. I just tried that. Still nothing.

    Like 'attn%' does work
    OK and you explicitly specified WITH STOPLIST = OFF in your code?

    What version of SQL Server btw?
    The greatest trick the devil ever pulled was convincing the world that he didn't exist

  8. #8

    Potty-trained

    suityou01's Avatar
    Join Date
    Jan 2009
    Location
    Skid row
    Posts
    20,965
    Thanks (Given)
    177
    Thanks (Received)
    208
    Likes (Given)
    742
    Likes (Received)
    713

    Default

    Quote Originally Posted by MrMarkyMark View Post
    No Wildcard
    You don't always need a wild card. I understand this would force a full table scan, which kind of negates the effect of going to all the trouble of creating a full text index. Contains should match on the string wherever your search string occurs.
    Embrace your inner weird.

  9. #9

    Potty-trained

    suityou01's Avatar
    Join Date
    Jan 2009
    Location
    Skid row
    Posts
    20,965
    Thanks (Given)
    177
    Thanks (Received)
    208
    Likes (Given)
    742
    Likes (Received)
    713

    Default

    Quote Originally Posted by LondonManc View Post
    OK and you explicitly specified WITH STOPLIST = OFF in your code?
    I did do the following

    Code:
    ALTER FULLTEXT INDEX ON MyFullTextTable SET STOPLIST = OFF
    Edit : 2012
    Embrace your inner weird.

  10. #10

    Double Godlike!


    Join Date
    Dec 2012
    Posts
    10,224
    Thanks (Given)
    728
    Thanks (Received)
    710
    Likes (Given)
    4820
    Likes (Received)
    2796

    Default

    Quote Originally Posted by suityou01 View Post
    Thanks LM. I just tried that. Still nothing.
    Like 'attn%' does work
    If my column contains 'Attrn'
    Why would it???

    % just looks for Unknowns at the end of your string?

    The "r" isn't at the end..

+ Reply to Thread
Page 1 of 5 1 2 3 ... LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Content Relevant URLs by vBSEO 3.6.0 ©2011, Crawlability, Inc.