• Visitors can check out the Forum FAQ by clicking this link. You have to register before you can post: click the REGISTER link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. View our Forum Privacy Policy.
  • Want to receive the latest contracting news and advice straight to your inbox? Sign up to the ContractorUK newsletter here. Every sign up will also be entered into a draw to WIN £100 Amazon vouchers!

FullText Search - SQL Server

Collapse
X
  •  
  • Filter
  • Time
  • Show
Clear All
new posts

    #31
    And no, sadly a wildcard doesn't make any difference. Still nada.

    Thanks for trying chaps.

    Edit : I just got this to work.

    SELECT * FROM MyTable WHERE Contains(MyField,'Exactlymatchingstring')

    This works. But

    SELECT * FROM MyTable WHERE Contains(MyField,'Exactlymatchi')

    does not work.
    Last edited by suityou01; 28 March 2017, 15:35.
    Knock first as I might be balancing my chakras.

    Comment


      #32
      Originally posted by suityou01 View Post
      And no, sadly a wildcard doesn't make any difference. Still nada.

      Thanks for trying chaps.

      Edit : I just got this to work.

      SELECT * FROM MyTable WHERE Contains(MyField,'Exactlymatchingstring')

      This works. But

      SELECT * FROM MyTable WHERE Contains(MyField,'Exactlymatchi')

      does not work.
      Ahem.....

      Originally posted by LondonManc View Post
      Yep, I think this is the key - "Attrn" is not recognised as a logical linguistic extension of "Att". I finally cheated and RTFM
      The greatest trick the devil ever pulled was convincing the world that he didn't exist

      Comment


        #33
        Originally posted by LondonManc View Post
        Ahem.....
        Not getting it.

        How is "Exactlymatchinstri' a word, but 'Exactlymatchingstring' isn't?
        Knock first as I might be balancing my chakras.

        Comment


          #34
          Originally posted by suityou01 View Post
          Not getting it.

          How is "Exactlymatchinstri' a word, but 'Exactlymatchingstring' isn't?
          It's to do with stemming.

          Grab a coffee and have a read through this:
          https://blogs.msdn.microsoft.com/sql...sing-contains/
          The greatest trick the devil ever pulled was convincing the world that he didn't exist

          Comment


            #35
            Originally posted by suityou01 View Post
            Not getting it.

            How is "Exactlymatchinstri' a word, but 'Exactlymatchingstring' isn't?
            Because you either need a "*" wildcard or to include something extra like FORMSOF, INFLECTIONAL and / or FREETEXT rather than just CONTAINS.
            Best Forum Advisor 2014
            Work in the public sector? You can read my FAQ here
            Click here to get 15% off your first year's IPSE membership

            Comment


              #36
              Originally posted by suityou01 View Post
              And no, sadly a wildcard doesn't make any difference. Still nada.

              Thanks for trying chaps.

              Edit : I just got this to work.

              SELECT * FROM MyTable WHERE Contains(MyField,'Exactlymatchingstring')

              This works. But

              SELECT * FROM MyTable WHERE Contains(MyField,'Exactlymatchi')

              does not work.
              Worth as much as you have paid for it.

              I trust this is for some hobby project and no one is paying for your SQL Server "expertise"
              The Chunt of Chunts.

              Comment


                #37
                Originally posted by suityou01 View Post
                Not getting it.

                How is "Exactlymatchinstri' a word, but 'Exactlymatchingstring' isn't?
                That's the opposite of what you said

                What's syntax are you using for your wildcard match?


                Originally posted by suityou01 View Post
                And no, sadly a wildcard doesn't make any difference. Still nada.

                Thanks for trying chaps.

                Edit : I just got this to work.

                SELECT * FROM MyTable WHERE Contains(MyField,'Exactlymatchingstring')

                This works. But

                SELECT * FROM MyTable WHERE Contains(MyField,'Exactlymatchi')

                does not work.

                Comment


                  #38
                  I've not touched fts for years, but it is basically looking for words, without wildcards it works off the stems of whole words, so "story" or "stories" are the same, as are tenses such as "going" and "gone". This used to show up in Sharepoint, where searches for, say, product IDs unless fully qualified failed miserably.
                  Last edited by BigRed; 28 March 2017, 23:06.

                  Comment


                    #39
                    Originally posted by LondonManc View Post
                    It's to do with stemming.

                    Grab a coffee and have a read through this:
                    https://blogs.msdn.microsoft.com/sql...sing-contains/
                    Originally posted by BigRed View Post
                    I've not touched fts for years, but it is basically looking for words, without wildcards it works off the stems of whole words, so "story" or "stories" are the same, as are tenses such as "going" and "gone". This used to show up in Sharepoint, where searches for, say, product IDs unless fully qualified failed miserably.
                    If he reads the blog post that I linked to, rather than waiting to be spoonfed the answer, he'd know that by now.
                    The greatest trick the devil ever pulled was convincing the world that he didn't exist

                    Comment


                      #40
                      Originally posted by LondonManc View Post
                      If he reads the blog post that I linked to, rather than waiting to be spoonfed the answer, he'd know that by now.
                      Yes but the wildcard doesn't work. I'm sure I mentioned this before.
                      Knock first as I might be balancing my chakras.

                      Comment

                      Working...
                      X