Documentation
(C) IBM Corp. 1996, 1999

Text Extender: Administration and Programming


Chapter 15. Sample API program

Text Extender provides a sample program, DESSAMP1.C, located in the SAMPLES directory.

DESSAMP1.C is an example of a program that uses the DesGetSearchResultTable function and your own browser program. It follows the sequence of API function calls shown in Figure 13.

You need access to an enabled database and an enabled text column. To run this program, do the following:

  1. Optional. Copy the source file DESSAMP1.C to a local directory on your client machine.

  2. Use the supplied makefile (DESSAMP.MAK for OS/2 and Windows NT, dessamp for UNIX systems) to compile and link the sample files.

  3. Run the utility DESRESTB to create a result table in the database that you intend to use with the sample code:
    DESRESTB database-name
    

    This table is used to store information such as the search results; it has the following structure:
    Column Data type
    HANDLE DB2TX.DB2TEXTH or DB2TX.DB2TEXTFH
    RANK DOUBLE
    MATCHES INTEGER


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]