By submitting your personal information, you agree that TechTarget and its partners may contact you regarding relevant content, products and special offers.
Companies often acquire Microsoft Office SharePoint 2007 (MOSS) for its enterprise search capabilities. The problem with SharePoint 2007's enterprise search feature is that it doesn't, by default, provide granular search results. It filters all possible SharePoint content sources, thereby returning a large number of search results.
If you want to isolate your query to a specific SharePoint document library or extranet site from within the portal, you need to set boundaries to specify which portion of the SharePoint portal should serve as the search source to provide a more granular result set. In the SharePoint vernacular, this is called Search Scopes.
Along with enterprise search, SharePoint is also known for its document management capability. Frequently, companies set one or more SharePoint sites to serve as a document repository and traditionally require that a search scope be limited to a specific document site or a document library.
To achieve this functionality, you will need to create custom search scopes. Because search in SharePoint is a shared service, the ability to create custom global search scopes is offered only through a Shared Services Provider (SSP) administrative site. The SSP administration site is available through Central Administration.
NOTE: You must have administrative rights to the Shared Services Provider administrative site to create a global custom search scope in SharePoint.
To do so:
- Click Search Settings under the Search section. Then click on View Scopes. You will notice under the Shared group that two search scopes already exist: All Sites and People. These two search scopes are provided by default after creating the SSP administrative site.
- Click on New Scope and enter a meaningful name for your custom search scope in the Title field. The name should indicate where the scope search results are set (e.g., "Document Libraries"). The default contact for the search scope is the person creating it, but a different account can be specified as well. Click OK.
You will see the new search scope name appear in the list of search scopes. The search scope is empty and will remain this way until you specify a set of rules for the population of items for this scope.
- Click on Add Scope Rule. Select Web Address as the rule type and set the URL to point to the SharePoint documents library or site to which you want to limit the search scope. You can also specify file folders in your file system by using UNC name with "file" prefix in the URL. In the Behavior section, the Include option is selected by default to include all items that match this rule (Figure 1). Click OK.
The new search scope will be populated only after the scopes update process completes. To trigger an update manually without waiting for it to run on its schedule, click Start Update Now under Scopes on the search settings page.
Custom scopes are not available within site collections until the site collection administrator adds them manually. This gives administrators control over which scopes are available for use within search web parts in sites within the site collection.
- Go to Site Collection -> Site Settings.
- Under Site Collection Administration, click on Search Scopes. You can now add your custom search scope to this site collection and make it available to any SharePoint sites as well as in the global search box. Grouping scopes is another to organize them.
Search scopes can also be set to specific content sources such as SharePoint websites, managed properties, system file folders and Exchange public folders.
About the author: Natalya Voskresenskaya, MCTS, is SharePoint Architect at Conchango, a consultancy and system integration company. She has been working in the IT field for 10 years. With experience in design, architecture, development and deployment of Web-based applications, Natalya has been developing portal solutions since 2000 and started working with SharePoint since version 2003. For more information, check out Natalya's SharePoint blog.