phillips1021
|
Posted: August 29, 2010 21:20 by phillips1021
|
|
When trying to insert a new book using the chapter 10 code example I get this exception after clicking on the Create a book button: Caused by: java.lang.UnsupportedOperationException at org.eclipse.persistence.internal.jpa.EntityManagerImpl.createNamedQuery(EntityManagerImpl.java:974) at com.sun.enterprise.container.common.impl.EntityManagerWrapper.createNamedQuery(EntityManagerWrapper.java:555) at org.beginningee6.book.chapter10.BookEJB.findBooks(BookEJB.java:33) |
Chapter 10 Code Example
Replies: 5 - Last Post: January 10, 2011 22:08
by: denizkiyisi
by: denizkiyisi
showing 1 - 6 of 6
MarcusDidius
|
Posted: October 15, 2010 12:35 by MarcusDidius
|
|
I get the same error. Have you found a solution? |
agoncal
|
Posted: December 30, 2010 08:53 by agoncal
|
|
I'm using GlassFish 3.0.1b22 and it works fine for me. This is a pb of EclipseLink version. The very first 2.0.x version didn't implement Named Query with TypedQuery : TypedQuery<Book> query = em.createNamedQuery("findAllBooks", Book.class); But the last versions do (and the latest version of GlassFish include the latest version of EclipseLink). |
agoncal
|
Posted: December 30, 2010 08:54 by agoncal
|
|
I'm using GlassFish 3.0.1b22 and it works fine for me. This is a pb of EclipseLink version. The very first 2.0.x version didn't implement Named Query with TypedQuery : TypedQuery<Book> query = em.createNamedQuery("findAllBooks", Book.class); But the last versions do (and the latest version of GlassFish include the latest version of EclipseLink). |
denizkiyisi
|
Posted: January 10, 2011 00:28 by denizkiyisi
|
|
Hi, this project running good but i have a problem with project urls. if i click new book commandLink in firefox coming new book page but in project url shows still http://localhost:8080/BookApp/listBooks.faces. if i entering values for new book and click create a book commandButton, new book saved and navigate BookLists but in firefox shows still http://localhost:8080/BookApp/newBook.faces old new book url. is this a bug from jsf 2 or glassfish ? or i make wrong in settings? i am testing in netbeans + glassfish 3 in localhost. thanks. deniz. |
denizkiyisi
|
Posted: January 10, 2011 22:08 by denizkiyisi
|
|
Hi, i found a solution for the navigate problem. further informations in this article http://java.dzone.com/articles/fluent-navigation-jsf-2?page=0,0 the navigation solution is simple : return "newBook.faces?faces-redirect=true"; or return "newBook.xhtml?faces-redirect=true"; (for xhtml mapping instead *.faces) this make first redirect after rendering xhtml page and urls shows right ![]() thanks. deniz. |
showing 1 - 6 of 6
Replies: 5 - Last Post: January 10, 2011 22:08
by: denizkiyisi
by: denizkiyisi








