601,100
562,"NULL"
586,
585,
564,
565,"hdlITYA=aXVZ0>^Uf9^=h95`T[?@`mW@^D@dP1qeGChysxRHEG^t7rOzUyu44xJl@N209kEc1Lwprgy]sfWi2XKu^Ei>BVa\rTR;[AlP@TDNto7c=\gHQNj1xKdMbbhfxP6f\lY=>;q[i@pyQ32[UQ^I;1cP@6vjuNVyhqFvXOhlwCWf\:;au\xNR\bkOj0^47p]Uz]>"
559,0
593,
594,
595,
597,
598,
596,
800,
801,
566,0
567,","
588,"."
589,
568,""""
570,
571,
569,0
592,0
599,1000
560,0
561,0
590,0
637,0
577,0
578,0
579,0
580,0
581,0
582,0
572,128

#****GENERATED STATEMENTS START****
#****GENERATED STATEMENTS FINISH****

vAllTaskDim = 'pm_all_task';
vCountDim = 'pm_all_task_measures';
vStatsDim = 'pm_task_statistics';
vStatsMeasuresDim = 'pm_task_statistics_measures';
vStatusDim = '}sm_task_status';
vPlanDim = '}sm_plans';

vCountCube = 'pm_all_task';
vStatsCube = 'pm_task_statistics';

vAllPlans = 'All Plans';
vAllStatus = 'All Task Status';
vAllPlanTasks = 'All Plan Tasks';
vAvgDaysToComplete = 'Average days to Complete';
vOverdueTasks = 'Number of Overdue Tasks';
vAvgDaysOverdue = 'Average days Overdue';
vCount = 'Count';
vPct = 'Percent';

vDim = vAllTaskDim;
IF (DIMENSIONEXISTS(vDim) = 0);
DIMENSIONCREATE(vDim);
ENDIF;
ATTRINSERT( vAllTaskDim , '', 'Task', 'S');
ATTRINSERT( vAllTaskDim , '', 'Name', 'A');
ATTRINSERT( vAllTaskDim, '', 'Plan', 'S');
ATTRINSERT( vAllTaskDim, '', 'Version', 'S');
ATTRINSERT( vAllTaskDim, '', 'Version Task Dimension', 'S');

IF (DIMIX(vAllTaskDim, vAllPlans) = 0);
DIMENSIONELEMENTINSERT(vAllTaskDim, '', vAllPlans, 'C');
ENDIF;
IF (DIMIX(vAllTaskDim, vAllPlanTasks ) = 0);
DIMENSIONELEMENTINSERT(vAllTaskDim, '', vAllPlanTasks , 'C');
ENDIF;

vDim = vCountDim ;
IF (DIMENSIONEXISTS(vDim) = 0);
DIMENSIONCREATE(vDim);
ENDIF;
IF (DIMIX( vCountDim , vCount ) = 0);
DIMENSIONELEMENTINSERT( vCountDim , '', vCount , 'N');
ENDIF;
IF (DIMIX( vCountDim , vPct ) = 0);
DIMENSIONELEMENTINSERT( vCountDim , '', vPct , 'N');
ENDIF;

vDim = vStatsDim ;
IF (DIMENSIONEXISTS(vDim) = 0);
DIMENSIONCREATE(vDim);
ENDIF;
IF (DIMIX( vStatsDim , vAvgDaysToComplete ) = 0);
DIMENSIONELEMENTINSERT( vStatsDim , '', vAvgDaysToComplete , 'N');
ENDIF;
IF (DIMIX(vStatsDim , vOverdueTasks ) = 0);
DIMENSIONELEMENTINSERT( vStatsDim , '', vOverdueTasks , 'N');
ENDIF;
IF (DIMIX(vStatsDim , vOverdueTasks ) = 0);
DIMENSIONELEMENTINSERT( vStatsDim , '', vOverdueTasks , 'N');
ENDIF;

vDim = vStatsMeasuresDim ;
IF (DIMENSIONEXISTS(vDim) = 0);
DIMENSIONCREATE(vDim);
ENDIF;

IF (DIMIX(vStatusDim , vAllStatus  ) = 0);
DIMENSIONELEMENTINSERT(vStatusDim , '', vAllStatus  , 'C');
ENDIF;
vStatusCtr = DIMSIZ(vStatusDim);
vStatusIndex = 1;
WHILE (vStatusIndex <= vStatusCtr);
vStatus = DIMNM(vStatusDim, vStatusIndex);
IF (ELLEV(vStatusDim, vStatus) = 0);
DIMENSIONELEMENTCOMPONENTADD(vStatusDim, vAllStatus, vStatus, 1);
ENDIF;
vStatusIndex = vStatusIndex + 1;
END;


IF (CUBEEXISTS(vCountCube) = 0);
CUBECREATE(vCountCube,
vAllTaskDim,
vStatusDim,
vCountDim);
ENDIF;

vPlanIndex = 1;
vPlanCtr = DIMSIZ(vPlanDim);
WHILE (vPlanIndex <= vPlanCtr);
vPlan = DIMNM(vPlanDim, vPlanIndex);

DIMENSIONELEMENTCOMPONENTADD( vAllTaskDim, vAllPlans, vPlan, 1);

vThisPlanDim = '}sm_versions@' | vPlan;
IF (DIMENSIONEXISTS( vThisPlanDim ) <> 0);
vVersionCtr = DIMSIZ( vThisPlanDim );
vVersionIndex = 1;
WHILE (vVersionIndex <= vVersionCtr);
vVersion = DIMNM( vThisPlanDim , vVersionIndex);

DIMENSIONELEMENTCOMPONENTADD( vAllTaskDim, vPlan, vPlan | ' - ' | vVersion, 1);

vVersionDim = '}sm_versiontasks@' | vPlan | '@' | vVersion;
IF (DIMENSIONEXISTS( vVersionDim ) <> 0);
vTaskCtr = DIMSIZ( vVersionDim );
vTaskIndex = 1;
WHILE (vTaskIndex <= vTaskCtr);
vTask = DIMNM( vVersionDim, vTaskIndex);
vTaskElement = vPlan | ' - ' | vVersion | ' - ' | vTask;
DIMENSIONELEMENTCOMPONENTADD( vAllTaskDim, vPlan | ' - ' | vVersion, vTaskElement, 1);
vTaskName = ATTRS( vVersionDim, vTask, 'Name');
DIMENSIONELEMENTCOMPONENTADD( vAllTaskDim, vAllPlanTasks, vTaskName, 1);
DIMENSIONELEMENTCOMPONENTADD( vAllTaskDim, vTaskName, vTaskElement, 1);

vTaskIndex = vTaskIndex + 1;
END;
ENDIF;
vVersionIndex = vVersionIndex + 1;
END;
ENDIF;

vPlanIndex = vPlanIndex + 1;
END;
573,3

#****GENERATED STATEMENTS START****
#****GENERATED STATEMENTS FINISH****
574,3

#****GENERATED STATEMENTS START****
#****GENERATED STATEMENTS FINISH****
575,49

#****GENERATED STATEMENTS START****
#****GENERATED STATEMENTS FINISH****

vPlanIndex = 1;
vPlanCtr = DIMSIZ(vPlanDim);
WHILE (vPlanIndex <= vPlanCtr);
vPlan = DIMNM(vPlanDim, vPlanIndex);

vAlias = ATTRS( vPlanDim, vPlan, 'Plan');
ATTRPUTS(vAlias, vAllTaskDim, vPlan, 'Name');
ATTRPUTS( vPlan, vAllTaskDim, vPlan  , 'Plan');

vThisPlanDim = '}sm_versions@' | vPlan;
IF (DIMENSIONEXISTS( vThisPlanDim ) <> 0);
vVersionCtr = DIMSIZ( vThisPlanDim );
vVersionIndex = 1;
WHILE (vVersionIndex <= vVersionCtr);
vVersion = DIMNM( vThisPlanDim , vVersionIndex);
vVersionElement =   vPlan | ' - ' | vVersion;
vVersionDim = '}sm_versiontasks@' | vPlan | '@' | vVersion;
vAlias = ATTRS( vThisPlanDim, vVersion, 'Version');
ATTRPUTS( vPlan, vAllTaskDim, vVersionElement , 'Plan');
ATTRPUTS( vVersion, vAllTaskDim, vVersionElement , 'Version');
ATTRPUTS( vVersionDim , vAllTaskDim, vVersionElement , 'Version Task Dimension');


IF (DIMENSIONEXISTS( vVersionDim ) <> 0);
vTaskCtr = DIMSIZ( vVersionDim );
vTaskIndex = 1;
WHILE (vTaskIndex <= vTaskCtr);
vTask = DIMNM( vVersionDim, vTaskIndex);
vTaskElement = vVersionElement | ' - ' | vTask;

ATTRPUTS( vTask, vAllTaskDim, vTaskElement, 'Task');
ATTRPUTS( vPlan, vAllTaskDim, vTaskElement, 'Plan');
ATTRPUTS( vVersion, vAllTaskDim, vTaskElement, 'Version');
ATTRPUTS( vVersionDim , vAllTaskDim, vTaskElement, 'Version Task Dimension');
ATTRPUTS( ATTRS(vVersionDim, vTask, 'Name') | ' (' | vVersion | '-' | vPlan | ')', vAllTaskDim, vTaskElement, 'Name');

vTaskIndex = vTaskIndex + 1;
END;
ENDIF;
vVersionIndex = vVersionIndex + 1;
END;
ENDIF;

vPlanIndex = vPlanIndex + 1;
END;
576,CubeAction=1511	DataAction=1503	CubeLogChanges=0	
638,1
804,0
900,
901,
902,
903,
906,
907,
908,
904,0
905,0
909,0
910,0
911,
912,
913,
914,
915,
916,
