IBM Books

Image, Audio, and Video Extenders Administration and Programming

QbQueryGetString


Image Audio Video
X    

Returns the query string from a query. You can use the query string for input to UDFs in your application, for example in the UDF QbScoreFromStr or the API QbQueryStringSearch.

Authorization

None.

Library file
OS/2 and Windows AIX, HP-UX, and Solaris
dmbqqry.lib libdmbqqry.a (AIX)

libdmbqqry.sl (HP-UX)

libdmbqqry.so (Solaris)

Include file

dmbqbapi.h

Syntax

SQLRETURN QbQueryGetString(
      QbQueryHandle qObj,
      (char*)*  queryString
      );

Parameters

qObj (in)
The handle of the query object.

queryString (out)
The pointer to the query string for the query object.

Error codes

qbiECinvalidQueryHandle
The query handle that you specified does not reference a valid query.

Examples

Return the query string for the query object identified by the handle qrHandle.

#include <dmbqbapi.h>
 
SQLRETURN  rc;
char *queryString;
QbQueryHandle qrHandle
 
rc = QbQueryGetString(qrHandle, &queryString);
if (rc == 0)  {
   ...                  /* use the returned queryString for input to UDFs */
   free((void*)queryString);  /* you must free queryString  */
   queryString=(char*)0;
}


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