[JBoss Seam] - Problems when generating entities
by adriju
Hi!! I am new in all this world and I have problems with the Seam.
First, I am using an Oracle 9.2 DB. There are tables that have simple primary-keys and others that have composite primary-keys. Other tables have foreign-keys and a mix of primary and foreign keys.
I want to generate the entities corresponding to each table of my DB using seam-gen. I create a project in Seam and then I type 'seam generate-entities' from which I receive a successful build. The problem comes when I type 'seam restart', I receive BUILD FAILED.
When I see inside my project I can see several generated files corresponding to the tables in the DB. For example, I have this table:
table GRUPOS_USUARIOS
(
COD_GRUPOS_USUARIOS NUMBER(10) not null,
NOMBRE_GRUPOS_USUARIOS VARCHAR2(60) null,
primary key (COD_GRUPOS_USUARIOS)
)
seam-gen generates 3 files GrupoUsuarios.java, GruposUsuariosHome.java and GruposUsuariosList.java.
And in other table that has a composite primary key:
table auditoria
(
fecha date not null,
cod_audit number(10) not null,
descripcion varchar2(256) not null,
aplicacion varchar2(64) not null,
equipo varchar2(16) not null,
primary key (fecha, cod_audit, equipo)
)
I get 4 files from generate-entities AuditoriaHome.java, Auditoria.java, AuditoriaList.java and AuditoriaId.java.
When I do seam restart I receive this error among other:
[javac] c:\DesarrolloJava\Workspace\Teldages\src\action\com\mydomain\Teldages\Auditori
aHome.java:26: isEmpty(java.lang.String) in org.jboss.seam.util.Strings cannot be applied
to (java.util.Date)
[javac] if (Strings.isEmpty(getAuditoriaId().getFecha()))
Could anyone help me? Do I have to modify the reveng.xml file?
Thanks in advance.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4107716#4107716
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4107716
18 years, 5 months
[JCA/JBoss] - Re: No suitable driver found for java:PostgresDS
by chewbacca
Hi vickyk,
I hope that is enough. Thanks for your help!
2007-11-26 09:58:25,531 DEBUG [org.jboss.web.tomcat.service.jasper.TagLibCache] Scanning for tlds in: file:/C:/Arquivos de programas/Javaware/jboss-4.2.2.GA/server/default/deploy/jboss-web.deployer/jstl.jar
2007-11-26 09:58:27,640 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/demo].[jsp]] Servlet.service() for servlet jsp threw exception
javax.servlet.jsp.JspException: Unable to get connection, DataSource invalid: "java.sql.SQLException: No suitable driver found for java:PostgresDS"
at org.apache.taglibs.standard.tag.common.sql.QueryTagSupport.getConnection(QueryTagSupport.java:276)
at org.apache.taglibs.standard.tag.common.sql.QueryTagSupport.doStartTag(QueryTagSupport.java:159)
at org.apache.jsp.demo_jsp._jspx_meth_sql_005fquery_005f0(demo_jsp.java:149)
at org.apache.jsp.demo_jsp._jspService(demo_jsp.java:94)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:373)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:336)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
at java.lang.Thread.run(Unknown Source)
2007-11-26 09:58:46,640 DEBUG [com.arjuna.ats.arjuna.logging.arjLogger] Periodic recovery - first pass <Seg, 26 Nov 2007 09:58:46>
2007-11-26 09:58:46,640 DEBUG [com.arjuna.ats.arjuna.logging.arjLogger] StatusModule: first pass
Andre
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4107710#4107710
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4107710
18 years, 5 months