title: HSQL org.hsqldb.HsqlException: invalid schema name
body: <p>I am using HSQL to run a number of unit tests on my java application. I am using Spring + Hibernate. I am having a problem when switching from MySQL to HSQL. The tests run perfectly on MySQL but whenever I change to HSQL I get the following exception:</p>
  
  <pre><code>Caused by: org.hsqldb.HsqlException: invalid schema name: LMS
  at org.hsqldb.error.Error.error(Unknown Source)
  at org.hsqldb.error.Error.error(Unknown Source)
  at org.hsqldb.SchemaManager.getSchemaHsqlName(Unknown Source)
  at org.hsqldb.SchemaManager.getSchemaName(Unknown Source)
  at org.hsqldb.Session.getSchemaName(Unknown Source)
  at org.hsqldb.SchemaManager.getTable(Unknown Source)
  at org.hsqldb.ParserDQL.readTableName(Unknown Source)
  at org.hsqldb.ParserDQL.readSimpleRangeVariable(Unknown Source)
  at org.hsqldb.ParserDML.compileInsertStatement(Unknown Source)
  at org.hsqldb.ParserCommand.compilePart(Unknown Source)
  at org.hsqldb.ParserCommand.compileStatement(Unknown Source)
  at org.hsqldb.Session.compileStatement(Unknown Source)
  at org.hsqldb.StatementManager.compile(Unknown Source)
  at org.hsqldb.Session.execute(Unknown Source)
  </code></pre>
  
  <p>My Spring configuration is the following:</p>
  
  <pre><code>&lt;bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource"&gt;
      &lt;property name="driverClassName" value="org.hsqldb.jdbc.JDBCDriver" /&gt;
      &lt;property name="url" value="jdbc:hsqldb:file:lms" /&gt;
      &lt;property name="username" value="SA"/&gt;
      &lt;property name="password" value=""/&gt;
  &lt;/bean&gt;
  
  
  &lt;bean id="sessionFactory" class="org.springframework.orm.hibernate3.annotation.AnnotationSessionFactoryBean"&gt;
      &lt;property name="dataSource" ref="dataSource" /&gt;
  
      &lt;property name="packagesToScan"&gt;
          &lt;list&gt;
              &lt;value&gt;com.dreamteam.lms.**.*&lt;/value&gt;
          &lt;/list&gt;
      &lt;/property&gt;
  
      &lt;property name="hibernateProperties"&gt;
          &lt;props&gt;
              &lt;!--&lt;prop key="hibernate.dialect"&gt;org.hibernate.dialect.MySQLDialect&lt;/prop&gt;--&gt;
              &lt;prop key="hibernate.dialect"&gt;org.hibernate.dialect.HSQLDialect&lt;/prop&gt;
              &lt;prop key="hibernate.generate_statistics"&gt;true&lt;/prop&gt;
              &lt;prop key="hibernate.show_sql"&gt;false&lt;/prop&gt;
              &lt;prop key="hibernate.cache.use_second_level_cache"&gt;true&lt;/prop&gt;
              &lt;prop key="hibernate.cache.use_query_cache"&gt;true&lt;/prop&gt;
              &lt;prop key="hibernate.cache.provider_class"&gt;net.sf.ehcache.hibernate.SingletonEhCacheProvider&lt;/prop&gt;
          &lt;/props&gt;
      &lt;/property&gt;
  &lt;/bean&gt;
  </code></pre>
  
  <p>Sample Annotation on one of my classes:</p>
  
  <pre><code>@Entity
  @Table(name = "answer", catalog = "lms")
  public class Answer implements Cloneable, Serializable, IPojoGenEntity, IAnswer {
  .
  .
  </code></pre>
  
  <p>Any insight would be appreciated.</p>
  
  <p>Regards
  Chris</p>