Join Martin Guidry for an in-depth discussion in this video Exploring enhancements to full text search, part of SQL Server 2012 New Features.
In this section I would like to talk about a small enhancement to searching data that is in a full text index. It's a pretty small change from 2008, but I think a very nice feature. It gives the developer a little more control. I'll be using the full text index we created in the previous movie. Now that full text index is on a file table. That is not necessary for this to work. What I'm going to demonstrate would work on any full text index whether it's connected to a file table or not.
I have staged a little code for you in your exercise files. I'll copy and paste that over into management studio. And what I have on the screen right now is actually something that would work in 2008. We are going to search for information that contains the word proud and the word Janelle and they have to be near one another. So I'll execute that. And we see both Memo3 and Memo2 have the word proud near the word Janelle.
In SQL 2008 this is about as far as I could take it. I didn't have any more options. In 2012 they've given me the option to say how far or how close we would like these words to be. So rather than near being some abstract concept we can actually put a hard number on it. I can say I want the proud to be within 12 words of the word Janelle. And we run that again and we get the same results.
But now if you start to think about if we're looking for a situation where someone is saying that proud of Janelle and those two words are 12 words apart they could actually be saying they're proud of something else. So I want them to be much closer. Let's demonstrate that where they are only four words apart. And now we only get one file, we just get Memo2.txt where those two words are within four words of one another. So again, this is a pretty small change over 2008, but I do like it. I always like any change that gives the developer more control.
So now rather than just saying the near I have the option to say exactly how many words apart these things should be.
- Choosing an edition
- Finding and downloading SQL Server 2012
- Using FileTables to enhance FileStream
- Searching unstructured data semantically
- Searching text
- Exploring the Watch, Quick Watch, and Quick Info windows
- Creating user-defined server roles
- Understanding the changes to replication
- Exploring new types of indexes and new options on indexes
- Accommodating changes to database structure