/* // $Id: //guest/julian_hyde/mondrian/src/main/mondrian/rolap/HierarchyUsage.java#1 $ // (C) Copyright 2002 Kana Software, Inc. // This software is subject to the terms of the Common Public License // Agreement, available at the following URL: // http://www.opensource.org/licenses/cpl.html. // (C) Copyright 2002 Kana Software, Inc. and others. // All Rights Reserved. // You must accept the terms of that agreement to use this software. // // jhyde, 21 March, 2002 */ package mondrian.rolap; /** * A <code>HierarchyUsage</code> is the usage of a hierarchy in the context * of a cube. Private hierarchies can only be used in their own * cube. Public hierarchies can be used in several cubes. The problem comes * when several cubes which the same public hierarchy are brought together * in one virtual cube. There are now several usages of the same public * hierarchy. Which one to use? It depends upon what measure we are * currently using. We should use the hierarchy usage for the fact table * which underlies the measure. That is what determines the foreign key to * join on. * * A <code>HierarchyUsage</code> is identified by * <code>(hierarchy.sharedHierarchy, factTable)</code> if the hierarchy is * shared, or <code>(hierarchy, factTable)</code> if it is private. * * @author jhyde * @since 21 March, 2002 * @version $Id: //guest/julian_hyde/mondrian/src/main/mondrian/rolap/HierarchyUsage.java#1 $ **/ abstract class HierarchyUsage { String factTable; String factSchema; /** The foreign key by which {@link #hierarchy} should be joined to * {@link #factTable}. **/ String foreignKey; /** * Returns true if the two strings are equal, or if both are null. **/ protected static boolean equals(String s1, String s2) { if (s1 == null || s2 == null) { return s1 == s2; } return s1.equals(s2); } } // End HierarchyUsage.java
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#1 | 1576 | Julian Hyde |
mondrian: fix dataset (add column customer.ordinal); create dataset for oracle; get queries working on oracle; get format strings working; refactor out new packages mondrian.rolap.agg and mondrian.rolap.sql. |