title: Not able to add JPA dependency into spring-boot project
body: <p>I am trying to add JPA Maven dependency to already created spring-boot project but I am getting following error:</p>
  
  <pre><code>Error: Could not find or load main class com.kame.demo.DemoApplication
  </code></pre>
  
  <p>When I remove it the error is gone. </p>
  
  <p><strong>pom.xml</strong></p>
  
  <pre><code>&lt;dependencies&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-web&lt;/artifactId&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;com.h2database&lt;/groupId&gt;
              &lt;artifactId&gt;h2&lt;/artifactId&gt;
              &lt;version&gt;1.4.196&lt;/version&gt;
              &lt;scope&gt;test&lt;/scope&gt;
          &lt;/dependency&gt;
  
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.tomcat&lt;/groupId&gt;
              &lt;artifactId&gt;tomcat-jasper&lt;/artifactId&gt;
              &lt;version&gt;8.5.32&lt;/version&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-test&lt;/artifactId&gt;
              &lt;scope&gt;test&lt;/scope&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-data-jpa&lt;/artifactId&gt;
          &lt;/dependency&gt;
      &lt;/dependencies&gt;
  </code></pre>
  
  <p><strong>application.properties</strong></p>
  
  <pre><code>spring.mvc.view.prefix=/pages/
  spring.mvc.view.suffix=.jsp
  
  spring.h2.console.enabled=true
  spring.datasource.platform=h2
  spring.datasource.url=jdbc:h2:mem:navin
  </code></pre>
  
  <p>I tried to find answer online but none was solution for me.</p>
  
  <p>Also tried to create > Spring starter project > an there immediately add JPA, Web and H2 but still same error.</p>
  
  <p>I am using STS IDE, is something related to it maybe?</p>