bobbyo Posted August 12, 2009 Share Posted August 12, 2009 I recently purchased the ultimate guides from jaspersoft in hopes of learning how to create schema that work with XML under jaspersoft, but I've hit a snag: The example 'foodmart Sales OLAP Schema', section A.2/p.95 in JA-Ultimate-Guide.3.5.pdf, does not work with the Schema Workbench. In particular, I cut-n-pasted the FoodMart Sales Olap Schema xml document (below, code) into a text file, then tried to open it with JasperAnalysis Schema Workbench Version: 3.5.4 but whe I tried File->Open on the file, I got a popup window with the error:Error opening shcmea -- Parsing Error: Could not open file C:\Documents....\Foodmart_sales_olap_schema.xml In Schema: In Cube: element <Dimension> is not of expected type mondrian.gui.MondrianGuiDef$RelationI don't see a <Table /> element for the Cube...is the example schema incorrect? Can you give a correct version of the schema?Thanks, Bobby O Code:A.2 FoodMart Sales OLAP Schema<?xml version="1.0" encoding="UTF-8"?><Schema name="FOODMART"><Cube name="SALES BY PRODUCT BY STORE"><Dimension name="PRODUCT"><Hierarchy hasAll="true" name="PRODUCT CLASS" primaryKey="product_id"primaryKeyTable="product"><Level column="product_family" name="PRODUCT FAMILY" table="product_class"uniqueMembers="true"/><Level column="product_department" name="PRODUCT DEPARTMENT" table="product_class"uniqueMembers="false"/><Level column="product_category" name="PRODUCT CATEGORY" table="product_class"uniqueMembers="false"/><Level column="product_subcategory" name="PRODUCT SUBCATEGORY" table="product_class"uniqueMembers="false"/><Level column="brand_name" name="BRAND NAME" table="product" uniqueMembers="false"/><Level column="product_name" name="PRODUCT NAME" table="product" uniqueMembers="true"/></Hierarchy></Dimension><Dimension name="STORE"><Hierarchy hasAll="true" name="STORE LOCATION" primaryKey="store_id"><Table name="store"/><Level column="store_country" name="STORE COUNTRY" uniqueMembers="true"/><Level column="store_state" name="STORE STATE" uniqueMembers="true"/><Level column="store_city" name="STORE CITY" uniqueMembers="false"/><Level column="store_name" name="STORE NAME" uniqueMembers="true"><Property column="store_type" name="STORE TYPE"/><Property column="store_manager" name="STORE MANAGER"/><Property column="store_sqft" name="STORE SQFT" type="Numeric"/><Property column="grocery_sqft" name="GROCERY SQFT" type="Numeric"/><Property column="frozen_sqft" name="FROZEN SQFT" type="Numeric"/><Property column="meat_sqft" name="MEAT SQFT" type="Numeric"/><Property column="coffee_bar" name="HAS COFFEE BAR" type="Boolean"/><Property column="store_street_address" name="STREET ADDRESS" type="String"/></Level></Hierarchy></Dimension><Measure aggregator="sum" column="store_sales" formatString="$#,###.00" name="STORESALES"/><Measure aggregator="count" column="product_id" formatString="#,###" name="SALES COUNT"/></Cube></Schema> Link to comment Share on other sites More sharing options...
kkelleher Posted May 14, 2010 Share Posted May 14, 2010 It's odd. I'm able to load the schema into JasperServer and create views against it with no problem, but I'm getting an error from the workbench (v3.5.4) when I try to load the schema there. I'm not sure if it's a bad schema or a problem with the workbench's validation mechanism. I fiddled with the schema a bit, but I wasn't able to find a quick fix to the schema. I've logged a defect for this in our internal system. Note that you can use the full foodmart schema, which is available in your JS install under samples/schemas.Thanks for pointing this out, and sorry for the long delay in replying,Kristen Link to comment Share on other sites More sharing options...
kkelleher Posted May 17, 2010 Share Posted May 17, 2010 Development confirms that this schema example is missing its TABLE reference for the fact table. I'll try to post the corrected example soon.Thanks,KristenPost Edited by kkelleher at 05/17/2010 23:23 Link to comment Share on other sites More sharing options...
kkelleher Posted May 18, 2010 Share Posted May 18, 2010 The corrected schema is attached. Thanks for bringing this to my attention! I'll get it corrected in the ultimate guide, too.Thanks,Kristen Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now