title: HSQLDB : user lacks privilege or object not found: USERS
body: <p>I am using <code>HSQLDB</code> along with <code>Spring</code>. Whenever I try to execute an insert statement I get the error <code>user lacks privilege or object not found: USERS</code>.
  <br>
  The <code>USERS</code> table clears exists in the <code>HSQLDB Database</code> yet I am encountering this error.
  <br><br>
  <code>HSQLDB Configuration</code></p>
  
  <pre><code>&lt;bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource"&gt;
      &lt;property name="driverClassName" value="org.hsqldb.jdbcDriver"/&gt;
      &lt;property name="url" value="jdbc:hsqldb:mem:."/&gt;
      &lt;property name="username" value="SA"/&gt;
      &lt;property name="password" value=""/&gt;
    &lt;/bean&gt;
  </code></pre>
  
  <p><br><br>
  OffersDAO.java</p>
  
  <pre><code>    public class OffersDAO {
  
      private JdbcTemplate jdbcTemplate;
  
      @Autowired
      public void setDataSource(DataSource dataSource) {
          this.jdbcTemplate = new JdbcTemplate(dataSource);
      }
  
      public void addUser(String email, String password) {
  
          String sql = "INSERT INTO USERS(EMAIL, PASSWORD) VALUES(?, ?)";
  
          jdbcTemplate.update(sql, email, password);
  
          System.out.println("ADDED USER : " + email + " , " + password);
  
  
      }
  
  }
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/hANZQ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/hANZQ.png" alt="enter image description here"></a></p>