EssGetDatabaseInfo

Gets a database's information structure, which contains non user-configurable parameters for the database. 

Syntax

ESS_FUNC_M EssGetDatabaseInfo (hCtx, AppName, DbName, ppDbInfo);
ParameterData TypeDescription

hCtx

ESS_HCTX_T

API context handle.

AppName

ESS_STR_T

Application name.

DbName

ESS_STR_T

Database name.

ppDbInfo

ESS_DBINFO_T

Address of pointer to receive allocated database info structure.

Notes

Return Value

If successful, this function returns a pointer to an allocated database info structure in ppDbInfo.

Access

This function requires the caller to have at least read access (ESS_PRIV_READ) to the specified database.

Example

ESS_FUNC_M
ESS_GetDbInfo (ESS_HCTX_T  hCtx,
               ESS_HINST_T hInst
              )
{
   ESS_FUNC_M        sts = ESS_STS_NOERR;
   ESS_PDBINFO_T    DbInfo;
   ESS_STR_T        AppName;
   ESS_STR_T        DbName;
   AppName = "Sample";
   DbName  = "Basic";
 
   sts = EssGetDatabaseInfo (hCtx, AppName,
         DbName, &DbInfo);
   if (!sts)
   {      
      if (DbInfo)
      {   
         EssFree (hInst, DbInfo);
      }
   }
   return(sts);
}

See Also