EssLROGetCatalog

Description

EssLROGetCatalog() retrieves a list of LRO catalog entries for a given data cell in an Essbase database.

Syntax

ESS_FUNC_M EssLROGetCatalog (hCtx, memCount, pMemComb, pulLROCount, ppLRODescList)
ESS_HCTX_T hCtx
ESS_ULONG_T memCount
ESS_PMBRNAME_T pMemComb
ESS_ULONG_T pulLROCount
ESS_PLRODESC_API_T pLRODescList

Parameters

hCtx Essbase API context handle.
memCount Number of members specified in pMemComb.
pMemComb Array of member names.
pulLROCount Number of LRO catalog entries returned to caller.
pLRODescList Address of pointer to the list of LRO catalog entries returned to caller.

Return Value

If successful, returns ESS_STS_NOERR. Otherwise, returns an error code.

Access

A call to this function requires read privileges (ESS_PRIV_READ) for the active database.

Example

ESS_FUNC_M ESS_LRO GetCatalog (ESS_HCTX_T hCtx, ESS_HINST_T hInst)
{
	ESS_PMBRNAME_T		pMemComb = NULL;
	ESS_PLRODESC_API_T	plroDescList=NULL;
	ESS_USHORT_T		usOption = 0;
	ESS_ULONG_T		memCount;
	ESS_FUNC_M 		sts = ESS_STS_NOERR;
	ESS_ULONG_T		ulLroCount;
	memCount = 5;
	sts = EssAlloc(hInst, memCount*sizeof(ESS_MBRNAME_T),
	               (ESS_PPVOID_T)&pMemComb);
	if(sts)
	{
		printf("Could not allocate memory \n");
		return sts;
	}
	memset(pMemComb, 0, memCount*sizeof(ESS_MBRNAME_T));
	strcpy( pMemComb[0], "Profit");
	strcpy( pMemComb[1], "East");
	strcpy( pMemComb[2], "Actual");
	strcpy( pMemComb[3], "Colas");
	strcpy( pMemComb[4], "Year");
	sts = EssLROGetCatalog(hCtx, memCount, pMemComb, &ulLroCount, &plroDescList);
	if (sts)
	{
		printf ("Could not get the catalog \n");
	}
	EssFree(hInst, pMemComb);
	if(plroDescList)
	{
		EssFree(hInst, pMemComb);
	}
	return sts;
}

See Also

LRO Constant and Structure Definitions
EssLROAddObject()
EssLROUpdateObject()
EssLROGetObject()
EssLRODeleteObject()