Interstage Shunsaku Data Manager Application Development Guide - Microsoft(R) Windows(R) 2000/ Microsoft(R) Windows Server(TM) 2003 - - UNIX -
Contents Index PreviousNext

Appendix N C APIs Used in V6.0L30 and Earlier

N.3 shunsearch1

mark1Function

Performs searches based on input parameters and reports the number of hits only to the source invoking this function.

mark1Syntax

#include         "libshun.h"
int     shunsearch1(
           char     *host_Name,   /* in  (1) Host name                 */
           int      Port_No,      /* in  (2) Port number               */
           char     *Query,       /* in  (3) Search expression area    */
           char     *Reserve,     /* in  (4) Reserved (NULL)           */
           int      *Hit_Cnt      /* out (5) Number of hits            */
);

mark1Return Value

The error code reported by this function is returned.

Value '0' is returned if the function completes normally.

The validity of the returned result cannot be guaranteed if a value other than '0' is returned.

Refer to N.7 Error Codes Output for details on error codes.

mark1Parameters

mark2(1) Host name

Specify the host name or IP address of the director server.

When the conductor function is to be used, specify the host name or IP address of the server where the conductor is running.

When the conductor function is not to be used, specify the host name or IP address of the server where the director is running.

The host name can be up to 24 bytes long.

mark2(2) Port number

Specifies the number of the port that receives requests from the director server or the number of the port that receives search requests.

When the conductor function is to be used, specify the MySearchPort parameter in the conductor environment file.

When the conductor function is not to be used, specify the MySearchPort parameter in the director environment file.

mark2(3) Search expression area

Specifies a pointer to the search expression area. For the search expression, specify a string that has been converted to the character code specified in CharacterCode in the director environment file. The size of the search expression area must be between 1 and 65, 535 bytes inclusive.

Refer to B.3 Search Expressions on search expressions.

mark2(4) Reserved

Specify NULL.

mark2(5) Number of hits

Returns the number of items that match the search condition.

Zero out the area storing the number of hits before specifying this parameter.


Contents Index PreviousNext

All Rights Reserved, Copyright(C) FUJITSU LIMITED 2006