Db2 Text Search

After you started the Db2 Text Search instance and a text search index is created for a text column, you can search the text data by issuing SQL and XQUERY statements.

Important: Net Search Extender (NSE) is no longer supported in Db2. Use the Db2 Text Search feature.

Db2 Text Search provides extensive capabilities for searching data in text columns that are stored in a database table. The search system provides fast query response times and a consolidated, ranked result set that quickly and easily locates the information that you require. By incorporating the functions of Db2 Text Search in your SQL and XQuery statements, you can create powerful and versatile text-retrieval programs. Furthermore, the search engine uses linguistic analysis to ensure that it returns only relevant search query results. By enabling text search support, you can use the CONTAINS, SCORE, and xmlcolumn-contains functions, which are built into the database engine, to search text search indexes that are based on the search arguments that you specify.

Db2 Text Search achieves high performance and scalability by using data streaming to avoid high resource consumption during search.

You can install the Db2 Text Search server and the database servers on the same system for an integrated text search server setup. You can also install Db2 Text Search server and the database server on different systems for a stand-alone setup. The Db2 Text Search server runs in its own Java™ Virtual Machine (JVM). You explicitly start and stop the Db2 Text Search services after the database instance is started. Use the stand-alone text search server release that corresponds with the database server release.

Figure 1. Deployment diagram for an integrated Db2 Text Search server
The Db2 Text Searchserver and the database server are on the same system

Db2 Text Search does not have a graphical user interface. Instead, command-line tools are available for tasks such as configuring and administering the Db2 Text Search server, creating a synonym dictionary for a collection, and diagnosing problems. In addition, you can use a stored-procedure interface for various common administrative tasks.

You can migrate from Net Search Extender to Db2 Text Search by creating and updating Db2 Text Search indexes and then toggling the index status when the indexes are ready for use. For details, see the topic about migration from Net Search Extender to Db2 Text Search.

You cannot search or modify Db2 Text Search indexes or collections that are created or modified by using 10.5 Text search by using an earlier release of the Db2 Text Searchh server.

Note: Db2 Text Search does not support clustering.
Db2 Text Search includes the following key features:
Tight integration with Db2
  • A stored procedure interface for administration commands
  • Installation and configuration that is performed by the database installer
  • Invisible authentication
  • SQL codes for error handling
Document indexing
  • Fast indexing of large amounts of data
  • pureXML® support
  • Multiple document format support
  • Incremental and asynchronous index updating
Advanced search technology
  • SQL, SQL/XML, and XQuery support
  • The CONTAINS and SCORE SQL functions
  • Built-in SQL functions that are combined with the database Optimizer
  • The xmlcolumn-contains XML function
  • XML filtering
  • Linguistic processing in all supported languages
  • Weight, wildcard, and optional term support
  • Synonym dictionary support