Sm_PolicyApi_CreateODBCQueryScheme()
Creates a new ODBC Query Scheme. An ODBC query scheme is used to create an ODBC directory. The attributes of the user directory are contained in the pstructODBCQueryScheme structure.
casso10
Creates a new ODBC Query Scheme. An ODBC query scheme is used to create an ODBC directory. The attributes of the user directory are contained in the
pstructODBCQueryScheme
structure.If the user ODBC query scheme object exists and the
bUpdate
flag is true, the item is updated.Type
ODBC query scheme function, global scope.
Syntax
int SM_EXTERN Sm_PolicyApi_CreateODBCQueryScheme (void*pSessionHandle,Sm_PolicyApi_ODBCQueryScheme_t*pstructODBCQueryScheme,const boolbUpdate);
Parameter | I/O | Description |
pSessionHandle
| I | A pointer to an internal Policy Management API data structure. The structure holds information about the administrator session and the client session. |
pstructODBCQueryScheme
| I | A pointer to a completely filled-in ODBC query scheme. |
bUpdate
| I | A flag to indicate that if an existing object is found, it should be updated. |
Returns
- Sm_PolicyApi_Success. The ODBC Query Scheme was created successfully.
- Sm_PolicyApi_Failure. The ODBC Query Scheme was not created successfully.
- Sm_PolicyApi_InvalidHandle. There was no valid initialization prior to this call.
- Sm_PolicyApi_NoSession. There is no valid administrator session.
- Sm_PolicyApi_NoPrivilege. The administrator does not have the privilege to create an ODBC Query Scheme.
- Sm_PolicyApi_InvalidOid. The ODBC Query Scheme OID was not found. This happens when this function is called withbUpdateset to true and thepszOidfield of Sm_PolicyApi_ODBCQueryScheme_t holds the OID of the ODBC Query Scheme being updated.
- Sm_PolicyApi_NotUnique. An ODBC Query Scheme with the same name exists.
- Sm_PolicyApi_MissingProperty. One of the required fields is not set.