# compares an existing xml representation of a database model against an actual database model
#
# The actual parameters are set in config\ddlutils.properties.
# The used database connection is defined in the referred absserver.properties
#
# You can also pass parameters as java parameters. The format is
# databaseUrl databaseUser databasePassword nameOfExpectedXMLModelZipFile
# where
#	databaseUrl 		      Represents the URL of the database to connect to, in format jdbc:oracle:oci8:@<SID>
#	databaseUser		      The name of the database user in <SID> to connect to
#	databasePasword		      The password of the database user in <SID> to connect to
#	nameOfExpectedXMLModelZipFile The full file name of the zipped xml file representing the expected data model.
#
# example
#	%JAVA_HOME%\bin\java.exe -Xmx512m absgroup.CompareSchemaToXML jdbc:oracle:oci8:@ABS1 UNI UNIPWD c:\abssolute\expectedUNImodel.xml.zip
#	Will compare the data model of user UNI, SID ABS1, with password UNIPWD against the zipped datamodel the zipped file c:\abssolute\expectedUNImodel.xml.zip

#!/bin/bash
#
################################################################################
export ORACLE_SID=ABST
export ORACLE_HOME=/abs/instantclient_11_2
export OJDBC_JAR=jdbc/lib/ojdbc6.jar   # Set the correct OJDBC jar file name here. The given path is as seen from $ORACLE_HOME
export JAVA_HOME=/abs/jdk1.6.0_23
export DDLUTILSPATH="/abs/1/Server/tools/ABSDDLUtils"
################################################################################
export CLASSPATH=$ORACLE_HOME/$OJDBC_JAR:$DDLUTILSPATH/lib/ABSDDLUtils.jar:$DDLUTILSPATH/lib:$CLASSPATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:$DDLUTILSPATH/Lib:$LD_LIBRARY_PATH
export PATH=$ORACLE_HOME/bin:$LD_LIBRARY_PATH:$JAVA_HOME/bin:$PATH

cd $DDLUTILSPATH/lib

java -Xmx512m absgroup.CompareSchemaToXML

