EssOtlDisassociateAttributeDimension

Disassociates an attribute dimension from a base dimension.

Syntax

ParameterData TypeDescription

hOutline;

ESS_HOUTLINE_T

Handle to the outline

hBaseDimension;

ESS_HMEMBER_T

Handle to the base dimension

hAttributeDimension;

ESS_HMEMBER_T

Handle to the attribute dimension

Notes

When you dissassociate an attribute dimension from a base dimension, you disassociate all members of the attribute dimension from members of the base dimension.

Example

void ESS_OtlDisassociateAttributeDimension()
{
   ESS_STS_T        sts = ESS_STS_NOERR;
   ESS_HOUTLINE_T   hOutline;
   ESS_HMEMBER_T    hBaseMbr;
   ESS_HMEMBER_T    hAttrMbr;
   ESS_OBJDEF_T     Object;
   ESS_APPNAME_T    szAppName;
   ESS_DBNAME_T     szDbName;
   ESS_OBJNAME_T    szFileName;
   ESS_PROCSTATE_T  pState;

   memset(&Object, '\0', sizeof(Object));
   Object.hCtx = hCtx;
   Object.ObjType = ESS_OBJTYPE_OUTLINE;
   strcpy(szAppName, "Sample");
   strcpy(szDbName, "Basic");
   strcpy(szFileName, "Basic");
   Object.AppName = szAppName;
   Object.DbName = szDbName;
   Object.FileName = szFileName;

   sts = EssOtlOpenOutline(hCtx, &Object, ESS_TRUE, ESS_TRUE, &hOutline);
   printf("EssOtlOpenOutline() sts: %ld\n",sts);

   sts = EssOtlFindMember(hOutline, "Product", &hBaseMbr);
   printf("EssOtlFindMember() sts: %ld\n",sts);

   sts = EssOtlFindMember(hOutline, "Color", &hAttrMbr);
   printf("EssOtlFindMember() sts: %ld\n",sts);

   sts = EssOtlDisassociateAttributeDimension(hOutline,hBaseMbr,hAttrMbr);
   printf("EssOtlDisassociateAttributeDimension() sts: %ld\n",sts);

   sts = EssOtlWriteOutline(hOutline, &Object);
   printf("EssOtlWriteOutline() sts: %ld\n",sts);

   sts = EssOtlRestructure(hCtx, ESS_DOR_ALLDATA);
   printf("EssOtlRestructure() sts: %ld\n",sts);

   if (!sts)
   {
      sts = EssGetProcessState (hCtx, &pState);
      while (!sts || (pState.State != ESS_STATE_DONE))
         sts = EssGetProcessState (hCtx, &pState);
   }
   sts = EssOtlCloseOutline(hOutline);
   printf("EssOtlCloseOutline() sts: %ld\n",sts);
}

See Also