{"id":153,"date":"2018-07-13T09:17:07","date_gmt":"2018-07-13T07:17:07","guid":{"rendered":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/?p=153"},"modified":"2025-08-13T10:18:14","modified_gmt":"2025-08-13T08:18:14","slug":"spooky-exceptions-10-an-exception-occurred-while-creating-a-query-in-entitymanager","status":"publish","type":"post","link":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/?p=153","title":{"rendered":"Spooky Exceptions (10) &#8211; An exception occurred while creating a query in EntityManager"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">Umgebung<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Wildfly 13<\/li>\n\n\n\n<li>EE7<\/li>\n\n\n\n<li>Eclipselink<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Situation<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Beim Aufruf einer JPA Query wird folgende Exception geworfen<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"> \n  2018-06-22 12:45:43,615 ERROR [org.jboss.as.ejb3.invocation] (default task-1) WFLYEJB0034: \n  EJB Invocation failed on component DataPrivacyStatementAcceptanceFacade\n  for method public abstract de.schoeso.festival.ejb.mde.DataPrivacyStatementAcceptanceList \n  de.schoeso.festival.ejb.mde.facade.DataPrivacyStatementAcceptanceFacadeLocal.findByVariousParameters(): javax.ejb.EJBException: \n  java.lang.IllegalArgumentException: An exception occurred while creating a query in EntityManager:  \n  Exception Description: Problem compiling [SELECT x FROM DataPrivacyStatementAcceptance x]. \n  [14, 44] The abstract schema type 'DataPrivacyStatementAcceptance' is unknown.\n\tat org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInNoTx(CMTTxInterceptor.java:223)\n\tat org.jboss.as.ejb3.tx.CMTTxInterceptor.supports(CMTTxInterceptor.java:418)\n<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">L\u00f6sung<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Ursache dieses Kompilierungsproblems und des fehlenden &#8222;abstract schema type&#8220; war, dass die Entit\u00e4t nicht in der persistence.xml eingetragen war (bzw. nicht erkannt wurde).<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Umgebung Situation Beim Aufruf einer JPA Query wird folgende Exception geworfen 2018-06-22 12:45:43,615 ERROR [org.jboss.as.ejb3.invocation] (default task-1) WFLYEJB0034: EJB Invocation failed on component DataPrivacyStatementAcceptanceFacade for method public abstract de.schoeso.festival.ejb.mde.DataPrivacyStatementAcceptanceList de.schoeso.festival.ejb.mde.facade.DataPrivacyStatementAcceptanceFacadeLocal.findByVariousParameters(): javax.ejb.EJBException: java.lang.IllegalArgumentException: An exception occurred while creating a query in EntityManager: Exception Description: Problem compiling [SELECT x FROM DataPrivacyStatementAcceptance x]. [14, 44] The abstract schema [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,7],"tags":[],"class_list":["post-153","post","type-post","status-publish","format-standard","hentry","category-jee","category-wildfly"],"_links":{"self":[{"href":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/index.php?rest_route=\/wp\/v2\/posts\/153","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=153"}],"version-history":[{"count":2,"href":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/index.php?rest_route=\/wp\/v2\/posts\/153\/revisions"}],"predecessor-version":[{"id":343,"href":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/index.php?rest_route=\/wp\/v2\/posts\/153\/revisions\/343"}],"wp:attachment":[{"href":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=153"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=153"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.schoenberg-solutions.de\/arndtblog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=153"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}