Examples of MdmLevelHierarchy


Examples of oracle.olapi.metadata.mdm.MdmLevelHierarchy

    println("\nUsing Shortcuts");
       
    MdmMeasure mdmUnitCost = getMdmMeasure("UNIT_COST_AW");
    MdmPrimaryDimension mdmProdDim = getMdmPrimaryDimension("PRODUCT_AW");
    MdmPrimaryDimension mdmTimeDim = getMdmPrimaryDimension("TIME_AW");
    MdmLevelHierarchy mdmProdHier = (MdmLevelHierarchy)
                                     mdmProdDim.getDefaultHierarchy();
    MdmLevelHierarchy mdmCalendar = (MdmLevelHierarchy)
                                     mdmTimeDim.getDefaultHierarchy();
       
    Source unitCost = mdmUnitCost.getSource();
    StringSource calendar = (StringSource) mdmCalendar.getSource();
    StringSource prodHier = (StringSource) mdmProdHier.getSource();
    Source timeSel = calendar.selectValues(new String[]
                                            {"CALENDAR_YEAR_AW::MONTH_AW::47",
                                             "CALENDAR_YEAR_AW::MONTH_AW::59"});
    Source prodSel = prodHier.selectValues(new String[]
View Full Code Here

Examples of oracle.olapi.metadata.mdm.MdmLevelHierarchy

    MdmPrimaryDimension mdmProdDim = getMdmPrimaryDimension("PRODUCT_AW");
    MdmPrimaryDimension mdmCustDim = getMdmPrimaryDimension("CUSTOMER_AW");
    MdmPrimaryDimension mdmTimeDim = getMdmPrimaryDimension("TIME_AW");
    MdmPrimaryDimension mdmChanDim = getMdmPrimaryDimension("CHANNEL_AW");
       
    MdmLevelHierarchy mdmProdHier = (MdmLevelHierarchy)
                                        mdmProdDim.getDefaultHierarchy();
    MdmLevelHierarchy mdmShipHier = (MdmLevelHierarchy)
                                      mdmCustDim.getDefaultHierarchy();
    MdmLevelHierarchy mdmCalendar = (MdmLevelHierarchy)
                                     mdmTimeDim.getDefaultHierarchy();
    MdmLevelHierarchy mdmChanHier = (MdmLevelHierarchy)
                                       mdmChanDim.getDefaultHierarchy();
       
    // Get the short description attribute for the dimensions, and the
    // Source objects for the attributes.
    MdmAttribute mdmProdShortDescr =
                               mdmProdDim.getShortValueDescriptionAttribute();
    Source prodShortDescr = mdmProdShortDescr.getSource();
    MdmAttribute mdmCustShortDescr =
                               mdmCustDim.getShortValueDescriptionAttribute();
    Source custShortDescr = mdmCustShortDescr.getSource();
    MdmAttribute mdmTimeShortDescr =
                               mdmTimeDim.getShortValueDescriptionAttribute();
    Source timeShortDescr = mdmTimeShortDescr.getSource();
   
    // Get the short description attribute for the channel dimension.
    MdmAttribute mdmChanShortDescr =
                               mdmChanDim.getShortValueDescriptionAttribute();
    Source chanShortDescr = mdmChanShortDescr.getSource();
       
    // Get the Source objects for the default hierarchies of the dimensions
    // of the measures
    Source prodHier = mdmProdHier.getSource();
    Source shipHier = mdmShipHier.getSource();
    Source calendar = mdmCalendar.getSource();
    Source chanHier = mdmChanHier.getSource();
       
    // Select values from the hierarchies
    Source prodSel = prodHier.join(prodHier.value(),
                                   getExpressDataProvider().createListSource(
                                      new String[]
View Full Code Here

Examples of oracle.olapi.metadata.mdm.MdmLevelHierarchy

    MdmPrimaryDimension mdmChanDim = getMdmPrimaryDimension("CHANNEL_AW");
    MdmPrimaryDimension mdmCustDim = getMdmPrimaryDimension("CUSTOMER_AW");
    MdmPrimaryDimension mdmProdDim = getMdmPrimaryDimension("PRODUCT_AW");
    MdmPrimaryDimension mdmTimeDim = getMdmPrimaryDimension("TIME_AW");
           
    MdmLevelHierarchy mdmChanHier = (MdmLevelHierarchy)
                                     mdmChanDim.getDefaultHierarchy();
    MdmLevelHierarchy mdmShipHier = (MdmLevelHierarchy)
                                     mdmCustDim.getDefaultHierarchy();
    MdmLevelHierarchy mdmProdHier = (MdmLevelHierarchy)
                                     mdmProdDim.getDefaultHierarchy();
    MdmLevelHierarchy mdmCalendar = (MdmLevelHierarchy)
                                     mdmTimeDim.getDefaultHierarchy();
       
    Source chanHier = mdmChanHier.getSource();
    Source shipHier = mdmShipHier.getSource();
    Source prodHier = mdmProdHier.getSource();
    Source calendar = mdmCalendar.getSource();
       
    // Create a list of the default hierarchies.
    ArrayList defaultHiers = new ArrayList(4);
    defaultHiers.add(chanHier);
    defaultHiers.add(shipHier);
View Full Code Here

Examples of oracle.olapi.metadata.mdm.MdmLevelHierarchy

    // Get the Source for the Product dimension.
    Source prodStdDim = mdmProdStdDim.getSource();
       
    // Get the default hierarchies of the dimensions and the Source objects
    // for them.
    MdmLevelHierarchy mdmCalendar =
                        (MdmLevelHierarchy) mdmTimeDim.getDefaultHierarchy();
    MdmLevelHierarchy mdmProdPrimary =
                     (MdmLevelHierarchy) mdmProdStdDim.getDefaultHierarchy();
    StringSource calendar = (StringSource) mdmCalendar.getSource();
    StringSource prodPrimary = (StringSource) mdmProdPrimary.getSource();
       
    // Get the Unit Cost and Unit Price measures and the Source objects for them.
    MdmMeasure mdmUnitCost = getMdmMeasure("UNIT_COST_AW");
    MdmMeasure mdmUnitPrice = getMdmMeasure("UNIT_PRICE_AW");
       
View Full Code Here

Examples of oracle.olapi.metadata.mdm.MdmLevelHierarchy

    getAllDecendents(mdmDeptDim,mdmDeptHier,"DEPT::1",false);
   
    System.out.println("Media:");
    MdmPrimaryDimension mdmMediaDim = getMdmPrimaryDimension("MEDIA");
   
    MdmLevelHierarchy mdmMediaHier = (MdmLevelHierarchy)
                                     mdmMediaDim.getDefaultHierarchy();
   
    getAllDecendents(mdmMediaDim,mdmMediaHier,"MEDIAHIER::ALL_MEDIA::ALL_MEDIA_0",true);
   
   
    System.out.println("Time:");   
    MdmPrimaryDimension mdmTimeDim = getMdmPrimaryDimension("MYTIME");
   
    MdmLevelHierarchy mdmTimeHier = (MdmLevelHierarchy)
                                     mdmTimeDim.getDefaultHierarchy();
    getAllDecendents(mdmTimeDim,mdmTimeHier,"TIMEHIER::MONTH::MONTH_2011-M01",false);
       
  }
View Full Code Here

Examples of oracle.olapi.metadata.mdm.MdmLevelHierarchy

public class OlapService {
 
  public static List getTimeDimensionTree() throws Exception{
    MyOlapContext context = MyOlapContext.getMyOlapContext();
    MdmPrimaryDimension mdmTimeDim = context.getMdmPrimaryDimension("MYTIME");
      MdmLevelHierarchy mdmTimeHier = (MdmLevelHierarchy)mdmTimeDim.getDefaultHierarchy();
//      StringSource prodHier =  (StringSource) mdmProdHier.getSource();

      MdmLevel mdmLevel = context.getLevelByName(mdmTimeHier, "YEAR");
      Source levelSrc = mdmLevel.getSource();
      StringSource timeHier = (StringSource) mdmTimeHier.getSource();
      // Get the Source for the short label attribute of the dimension.
      Source prodShortLabel = mdmTimeDim.getShortValueDescriptionAttribute()
                                        .getSource();
      Source levelSrcWithShortDescr = prodShortLabel.join(levelSrc);
      MdmAttribute mdmTimeHierParentAttr = mdmTimeHier.getParentAttribute();
      Source prodHierParentAttr = mdmTimeHierParentAttr.getSource();
      Source timeHierChildren = timeHier.join(prodHierParentAttr,
          timeHier.value());
      Cursor queryCursor = getCursor(context,levelSrcWithShortDescr);
      List<LazyDynaBean> result = convertDimensionShortDescCursor2List(queryCursor);
View Full Code Here

Examples of oracle.olapi.metadata.mdm.MdmLevelHierarchy

    // Get the Source objects for the attributes.
    Source prodShortDescr = mdmProdShortDescrAttr.getSource();
    Source timeShortDescr = mdmTimeShortDescrAttr.getSource();

    // Get the default hierarchies of the dimensions and their Source objects.
    MdmLevelHierarchy mdmProdHier = (MdmLevelHierarchy)
                                     mdmProdDim.getDefaultHierarchy();
    MdmLevelHierarchy mdmTimeHIer = (MdmLevelHierarchy)
                                     mdmTimeDim.getDefaultHierarchy();
    Source prodHier = mdmProdHier.getSource();
    StringSource timeHier = (StringSource) mdmTimeHIer.getSource();

    // Get the FAMILY level of the hierarchy and the Source for it.
      MdmLevel mdmFamilyLevel =
                     getContext().getLevelByName(mdmProdHier, "FAMILY_AW");
      Source prodSel = mdmFamilyLevel.getSource();
View Full Code Here

Examples of oracle.olapi.metadata.mdm.MdmLevelHierarchy

    // Get the level attribute of the dimension.
    MdmAttribute mdmTimeLevelAttr = mdmTimeDim.getLevelAttribute();

    // Get the default hierarchy of the dimension.
    MdmLevelHierarchy mdmTimeHier = (MdmLevelHierarchy)
                                     mdmTimeDim.getDefaultHierarchy();

    // Get the Source objects for the level attribute and the hierarchy.
      Source levelRel = mdmTimeLevelAttr.getSource();
      StringSource timeHier = (StringSource) mdmTimeHier.getSource();

    // Create a Source array containing the TIME levels.
    Source[] levelSources = new Source[3];
    List levels = mdmTimeHier.getLevels();
    for (int i = 0; i < levelSources.length; i++)
    {
      levelSources[i] = ((MdmLevel) levels.get(i)).getSource();
    }
    // Create a list Source that has the levels as element values.
View Full Code Here

Examples of oracle.olapi.metadata.mdm.MdmLevelHierarchy

    StringSource chanHier = (StringSource)
      getMdmPrimaryDimension("CHANNEL_AW").getDefaultHierarchy().getSource();
    StringSource timeHier = (StringSource)
      getMdmPrimaryDimension("TIME_AW").getDefaultHierarchy().getSource();

    MdmLevelHierarchy mdmProdHier = (MdmLevelHierarchy)
                                     mdmProdDim.getDefaultHierarchy();
    // Get the Source for the default product hierarchy                                   .
    StringSource prodHier = (StringSource) mdmProdHier.getSource();

    // Get the Source objects for the measure and for the default hierarchies
    // of the other dimensions.
    NumberSource units = (NumberSource) mdmUnits.getSource();

    // Get the parent attribute of the PRODUCT dimension and the Source for it
    // to use in the recursiveJoin method.
    MdmAttribute mdmProdParentAttr = mdmProdHier.getParentAttribute();
    Source prodParent = mdmProdParentAttr.getSource();

    // Get the short value description attribute and its Source.
    MdmAttribute mdmProdShortDescrAttr =
                                mdmProdDim.getShortValueDescriptionAttribute();
View Full Code Here

Examples of oracle.olapi.metadata.mdm.MdmLevelHierarchy

    Source units = mdmUnits.getSource();

    // Get the dimensions of the measure and the default hierarchies of
    // the dimensions.
    MdmPrimaryDimension mdmProdDim = getMdmPrimaryDimension("PRODUCT_AW");
    MdmLevelHierarchy mdmProdDefLvlHier = (MdmLevelHierarchy)
                                           mdmProdDim.getDefaultHierarchy();

    MdmPrimaryDimension mdmTimeDim = getMdmPrimaryDimension("TIME_AW");
    MdmLevelHierarchy mdmTimeDefLvlHier = (MdmLevelHierarchy)
                                           mdmTimeDim.getDefaultHierarchy();

    MdmPrimaryDimension mdmChanDim = getMdmPrimaryDimension("CHANNEL_AW");
    MdmLevelHierarchy mdmChanDefLvlHier = (MdmLevelHierarchy)
                                           mdmChanDim.getDefaultHierarchy();

    MdmPrimaryDimension mdmCustDim = getMdmPrimaryDimension("CUSTOMER_AW");
    MdmLevelHierarchy mdmCustDefLvlHier = (MdmLevelHierarchy)
                                           mdmCustDim.getDefaultHierarchy();

    // Get the Source objects for the hierarchies.
    StringSource prodHier = (StringSource) mdmProdDefLvlHier.getSource();
    StringSource timeHier = (StringSource) mdmTimeDefLvlHier.getSource();
    StringSource chanHier = (StringSource) mdmChanDefLvlHier.getSource();
    StringSource shipHier = (StringSource) mdmCustDefLvlHier.getSource();

    // Get the DataProvider.
    ExpressDataProvider dp = getExpressDataProvider();

    // Create NumberParameter objects for the starting and ending values
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.