Lists all the alias tables in the active database.
Syntax
ESS_FUNC_M EssListAliases (hCtx, pCount ppAliasList);
Parameter | Data Type | Description |
---|---|---|
hCtx | ESS_HCTX_T | API context handle. |
pCount | ESS_PUSHORT_T | Address of variable to receive count of alias tables. |
ppAliasList | ESS_PPALIASNAME_T | Address of pointer to receive an allocated array of alias table names. |
Notes
The memory allocated for ppAliasList should be freed using EssFree().
Return Value
If successful, this function returns a count of alias tables in pCount, and an allocated array of alias table names in ppAliasList.
Access
This function requires the caller to have at least read access (ESS_PRIV_READ) to the database, and to have selected it as the active database using EssSetActive().
Example
ESS_FUNC_M ESS_ListAliases (ESS_HCTX_T hCtx, ESS_HINST_T hInst ) { ESS_FUNC_M sts = ESS_STS_NOERR; ESS_USHORT_T Count; ESS_USHORT_T ind; ESS_PALIASNAME_T Altlist = NULL; sts = EssListAliases (hCtx, &Count, &Altlist); if (!sts) { if (Count && Altlist) { printf ("\r\n-----List of Aliases-----\r\n\r\n"); for (ind = 0; ind < Count; ind++) { if (Altlist [ind] != NULL) printf ("%s\r\n", Altlist[ind]); } EssFree (hInst, Altlist); } else printf ("\r\nAlias List is Empty\r\n\r\n"); } return (sts); }
See Also