Skip to content

Commit

Permalink
MONDRIAN: Fix for loading FoodMart from a file. Added load-foodmart A…
Browse files Browse the repository at this point in the history
…nt target. Updated developer guide about test database configuration and load-foodmart target

[git-p4: depot-paths = "//open/mondrian/": change = 11913]
  • Loading branch information
Sherman Wood committed Nov 7, 2008
1 parent b2830d0 commit 324afb8
Show file tree
Hide file tree
Showing 3 changed files with 152 additions and 76 deletions.
45 changes: 40 additions & 5 deletions build.xml
Expand Up @@ -341,14 +341,15 @@ demo/access/MondrianFoodMart.mdb"/>
<echo>==============================================================</echo>
<echo>| Mondrian configuration info |</echo>
<echo>==============================================================</echo>
<echo>project.location = ${project.location}</echo>
<echo>jdk.home = ${env.JAVA_HOME}</echo>
<echo>catalina.home = ${env.CATALINA_HOME}</echo>
<echo>junit.home = ${env.JUNIT_HOME}</echo>
<echo>log4j.configuration = ${log4j.configuration}</echo>
<echo>project.location = ${project.location}</echo>
<echo>jdk.home = ${env.JAVA_HOME}</echo>
<echo>catalina.home = ${env.CATALINA_HOME}</echo>
<echo>junit.home = ${env.JUNIT_HOME}</echo>
<echo>log4j.configuration = ${log4j.configuration}</echo>
<echo>mondrian.foodmart.catalogURL = ${mondrian.foodmart.catalogURL}</echo>
<echo>mondrian.foodmart.jdbcURL = ${mondrian.foodmart.jdbcURL}</echo>
<echo>mondrian.jdbcDrivers = ${mondrian.jdbcDrivers}</echo>
<echo>driver.classpath (additions) = ${driver.classpath}</echo>
<echo>==============================================================</echo>
</target>

Expand Down Expand Up @@ -1001,6 +1002,40 @@ buildJdk16.sh" />
<touch file="demo/derby/foodmart/service.properties"/>
</target>


<target name="load-foodmart"
depends="info"
description="load the foodmart database from the data file using the Mondrian loader. Assumes empty database exists">

<!--
Load from demo/FoodMartCreateData.zip directly - no need to unzip
Otherwise override, like
<arg value="-inputFile=demo/myData.sql"/>
<arg value="-inputFile=demo/myData.zip"/> - will access this without unzipping
You can override the JDBC batch size by setting the same property in your mondrian.properties.
Current using the default of 50 SQL statements per batch.
-->

<property name="mondrian.foodmart.loaderBatchSize" value="50" />

<java classname="mondrian.test.loader.MondrianFoodMartLoader"
classpathref="project.test.classpath"
fork="yes">
<arg value="-tables"/>
<arg value="-data"/>
<arg value="-indexes"/>
<arg value="-outputJdbcBatchSize=${mondrian.foodmart.loaderBatchSize}"/>
<arg value="-jdbcDrivers=${mondrian.jdbcDrivers}"/>
<arg value="-outputJdbcURL=${mondrian.foodmart.jdbcURL}"/>
<arg value="-outputJdbcUser=${mondrian.foodmart.jdbcUser}"/>
<arg value="-outputJdbcPassword=${mondrian.foodmart.jdbcPassword}"/>
</java>

</target>

<target name="release" depends="clean-deep, binzip, binDerbyzip"/>

<target name="upload">
Expand Down

0 comments on commit 324afb8

Please sign in to comment.