KB Article #177057

Using Interchange with a case insensitive database on a case sensitive MS SQL server

Problem

MS SQL server has the ability to create a case insensitive database on a case sensitive server. When used in conjunction with such a database, Interchange will be unable to start up with an error such as:

2013-06-18 08:29:45,899 - INFO  [Startup] (SchemaInstaller.installSchema:75) - Done loading schemas
2013-06-18 08:29:46,164 - ERROR [Startup] (UpgradeExecuter.executeUpgrades:68) - Error in executing upgrade class: com.cyclonecommerce.crossworks.upgrade.componentupgrade.RestructureCRLDirectory
java.lang.reflect.InvocationTargetException
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    ...
Caused by: kodo.util.DataStoreException: Database 'DATABASENAME' does not exist. Make sure that the name is entered correctly.
    at kodo.jdbc.sql.DBDictionary.newDataStoreException(DBDictionary.java:3403)
    ...
Caused by: java.sql.SQLException: Database 'DATABASENAME' does not exist. Make sure that the name is entered correctly.
    at net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:365)
    ... 
2013-06-18 08:29:46,179 - FATAL [Startup] (ControlNode.halt:90) - Fatal error while performing schema maintenance
com.cyclonecommerce.persistence.upgrade.UpgradeException: java.lang.reflect.InvocationTargetException
    at com.cyclonecommerce.persistence.upgrade.UpgradeExecuter.executeUpgrades(UpgradeExecuter.java:69)
    ...
Caused by: java.lang.reflect.InvocationTargetException
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    ... 
Caused by: kodo.util.DataStoreException: Database 'DATABASENAME' does not exist. Make sure that the name is entered correctly.
    at kodo.jdbc.sql.DBDictionary.newDataStoreException(DBDictionary.java:3403)
    ... 
Caused by: java.sql.SQLException: Database 'DATABASENAME' does not exist. Make sure that the name is entered correctly.
    at net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:365)
    ... 30 more


Resolution

This can be corrected via a property key in the .../Interchange/conf/datastoreconfig.xml file.

In the datastoreconfig.xml file, locate the ConnectionInfo with an id of "MSSQLServer". Within this ConnectionInfo, locate the Properties section.

There is usually at least one property already defined in this section.

Add the following line between the '<Properties>' and '</Properties>' lines:

<Property key="kodo.jdbc.DBDictionary" value="SchemaCase=preserve"/>