Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »


 
Returns a queryId that uniquely identifies an EDMquery function in the EDMdatabase.
Related functions: edmiGetQuerySchema , edmiDefineQuerySchema , edmiExecuteQuery , edmiExecuteQueryBN , edmiDeleteQuerySchema , edmiDeleteSchema
Header:
#include "sdai.h"
Prototype:
EdmiError edmiGetQuery (SdaiString  schemaName,
                         SdaiString  querySchemaName, 
                         SdaiString  queryName, 
                         SdaiQuery   *queryId); 
Arguments:

schemaName

Specifies the name of the Express schema (dictionary model) that hosts the query schema. This Express schema must exist as a dictionary model in the EDMdatabase . Schema names are case insensitive. Schema names are unique in an EDMdatabase .

querySchemaName

Specifies the name of the query schema of interest. Query schema names are case insensitive. Query schema names are unique within one dictionary model (Express schema).

queryName

Specifies the name of the query function (EDMquery) of interest. Query function names are case insensitive. Query schema names are unique within one query schema.

queryId

Address of the variable that will receive the numeric queryID that uniquely identifies the query function instance in the EDMdatabase .

Returns:
A completion code of datatype EdmiError is the returned function value. The completion code has the following values:
Completion code = 0 : Operation successfully performed.
Completion code != 0: Error in operation. Completion code is an EDMinterface error code. Use edmiGetErrorText to get the error text corresponding to the error code.
EXAMPLE
SdaiQuery queryId;
EdmiError rstat;
. . .
if (rstat = edmiGetQuery ("PDM_Schema",
"product_doc_approval", 
"product_documentation", 
&queryId)) { 
/* Error in operation */ 
printf("\nError: %s in edmiGetQuery \n", 
edmiGetErrorText(rstat)); 
goto error; 
}
printf ("\nQueryId: %lu", queryId);
. . .

  • No labels