11 Replies Latest reply on May 16, 2007 11:53 AM by Vladimir Ralev

    Error calling action method of component

    Sandy Dee Newbie

      Hi All,
      I used Seam Gen and developed a simple registration application in which i've registration page and a thank you page.In the registration page,I used <h:commmandButton value="Register" action="#{register.register}"> But when i click that register button i'm getting an error like


      javax.servlet.ServletException: Error calling action method of component with id register:register

      stacktrace is as follows


      2007-05-15 14:04:49,164 ERROR [org.jboss.seam.servlet.SeamExceptionFilter] uncaught exception
      javax.servlet.ServletException: Error calling action method of component with id register:register
      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:152)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.seam.servlet.SeamRedirectFilter.doFilter(SeamRedirectFilter.java:29)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:43)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
      at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
      at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      at org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
      at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
      at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
      at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
      at java.lang.Thread.run(Thread.java:595)
      2007-05-15 14:04:49,164 ERROR [org.jboss.seam.servlet.SeamExceptionFilter] exception root cause
      javax.faces.FacesException: Error calling action method of component with id register:register
      at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
      at javax.faces.component.UICommand.broadcast(UICommand.java:106)
      at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
      at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
      at org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343)
      at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.seam.servlet.SeamRedirectFilter.doFilter(SeamRedirectFilter.java:29)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:43)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
      at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
      at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      at org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
      at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
      at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
      at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
      at java.lang.Thread.run(Thread.java:595)
      Caused by: javax.faces.el.EvaluationException: /register.xhtml @18,81 action="#{register.register}": javax.ejb.EJBTransactionRolledbackException: java.lang.IllegalArgumentException: org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
      at com.sun.facelets.el.LegacyMethodBinding.invoke(LegacyMethodBinding.java:73)
      at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63)
      ... 32 more
      Caused by: javax.ejb.EJBTransactionRolledbackException: java.lang.IllegalArgumentException: org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
      at org.jboss.ejb3.tx.Ejb3TxPolicy.handleInCallerTx(Ejb3TxPolicy.java:93)
      at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:130)
      at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:201)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
      at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:131)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:47)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.stateless.StatelessContainer.localInvoke(StatelessContainer.java:211)
      at org.jboss.ejb3.stateless.StatelessLocalProxy.invoke(StatelessLocalProxy.java:79)
      at $Proxy121.register(Unknown Source)
      at com.vds.seamregistration.bean.Register$$FastClassByCGLIB$$c3cee60.invoke()
      at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
      at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:45)
      at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:74)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:55)
      at org.jboss.seam.intercept.RootInterceptor.createSeamInvocationContext(RootInterceptor.java:144)
      at org.jboss.seam.intercept.RootInterceptor.invokeInContexts(RootInterceptor.java:129)
      at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:102)
      at org.jboss.seam.intercept.ClientSideInterceptor.interceptInvocation(ClientSideInterceptor.java:83)
      at org.jboss.seam.intercept.ClientSideInterceptor.intercept(ClientSideInterceptor.java:52)
      at com.vds.seamregistration.bean.Register$$EnhancerByCGLIB$$9cf7a373.register()
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at com.sun.el.parser.AstValue.invoke(AstValue.java:151)
      at com.sun.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:283)
      at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)
      at com.sun.facelets.el.LegacyMethodBinding.invoke(LegacyMethodBinding.java:69)
      ... 33 more
      Caused by: java.lang.IllegalArgumentException: org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
      at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:628)
      at org.hibernate.ejb.AbstractEntityManagerImpl.createQuery(AbstractEntityManagerImpl.java:95)
      at org.jboss.ejb3.entity.TransactionScopedEntityManager.createQuery(TransactionScopedEntityManager.java:127)
      at com.vds.seamregistration.bean.RegisterAction.register(RegisterAction.java:29)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:112)
      at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:166)
      at org.jboss.seam.intercept.EJBInvocationContext.proceed(EJBInvocationContext.java:37)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:55)
      at org.jboss.seam.interceptors.BijectionInterceptor.bijectNonreentrantComponent(BijectionInterceptor.java:79)
      at org.jboss.seam.interceptors.BijectionInterceptor.bijectComponent(BijectionInterceptor.java:58)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
      at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
      at org.jboss.seam.interceptors.OutcomeInterceptor.interceptOutcome(OutcomeInterceptor.java:21)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
      at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
      at org.jboss.seam.interceptors.ConversationInterceptor.endOrBeginLongRunningConversation(ConversationInterceptor.java:52)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
      at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
      at org.jboss.seam.interceptors.MethodContextInterceptor.aroundInvoke(MethodContextInterceptor.java:27)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
      at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
      at org.jboss.seam.intercept.RootInterceptor.createSeamInvocationContext(RootInterceptor.java:144)
      at org.jboss.seam.intercept.RootInterceptor.invokeInContexts(RootInterceptor.java:129)
      at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:102)
      at org.jboss.seam.intercept.SessionBeanInterceptor.aroundInvoke(SessionBeanInterceptor.java:50)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:118)
      at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:126)
      ... 68 more
      Caused by: org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
      at org.hibernate.hql.ast.QueryTranslatorImpl.doCompile(QueryTranslatorImpl.java:204)
      at org.hibernate.hql.ast.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:111)
      at org.hibernate.engine.query.HQLQueryPlan.(HQLQueryPlan.java:77)
      at org.hibernate.engine.query.HQLQueryPlan.(HQLQueryPlan.java:56)
      at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache.java:72)
      at org.hibernate.impl.AbstractSessionImpl.getHQLQueryPlan(AbstractSessionImpl.java:133)
      at org.hibernate.impl.AbstractSessionImpl.createQuery(AbstractSessionImpl.java:112)
      at org.hibernate.impl.SessionImpl.createQuery(SessionImpl.java:1623)
      at org.hibernate.ejb.AbstractEntityManagerImpl.createQuery(AbstractEntityManagerImpl.java:92)
      ... 127 more
      2007-05-15 14:04:49,179 DEBUG [org.jboss.seam.util.Naming] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory, java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
      2007-05-15 14:04:49,179 DEBUG [org.jboss.seam.servlet.SeamExceptionFilter] ending request
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.exceptions
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.exceptions
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.exceptions
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.core.Events] Processing event:org.jboss.seam.preSetVariable.org.jboss.seam.core.exceptions
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.core.Events] Processing event:org.jboss.seam.postSetVariable.org.jboss.seam.core.exceptions
      2007-05-15 14:04:49,195 INFO [org.jboss.seam.core.Exceptions] reading exception mappings from /WEB-INF/pages.xml
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.util.DTDEntityResolver] trying to resolve system-id [http://jboss.com/products/seam/pages-1.1.dtd]
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.util.DTDEntityResolver] recognized Seam namespace; attempting to resolve on classpath under org/jboss/seam/
      2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.util.DTDEntityResolver] located [http://jboss.com/products/seam/pages-1.1.dtd] in classpath
      2007-05-15 14:04:49,210 DEBUG [org.jboss.mx.loading.RepositoryClassLoader] setRepository, repository=org.jboss.mx.loading.HeirarchicalLoaderRepository3@16e588e, cl=org.jboss.mx.loading.HeirarchicalLoaderRepository3$CacheClassLoader@32835b{ url=null ,addedOrder=0}
      2007-05-15 14:04:49,210 DEBUG [org.jboss.mx.loading.RepositoryClassLoader] setRepository, repository=org.jboss.mx.loading.HeirarchicalLoaderRepository3@16e588e, cl=org.jboss.mx.loading.HeirarchicalLoaderRepository3$CacheClassLoader@4df9a0{ url=null ,addedOrder=0}
      2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
      2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
      2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
      2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
      2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
      2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
      2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.core.Events] Processing event:org.jboss.seam.postCreate.org.jboss.seam.core.exceptions
      2007-05-15 14:04:49,210 ERROR [org.jboss.seam.exceptions.DebugPageHandler] redirecting to debug page
      org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
      at org.hibernate.hql.ast.QueryTranslatorImpl.doCompile(QueryTranslatorImpl.java:204)
      at org.hibernate.hql.ast.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:111)
      at org.hibernate.engine.query.HQLQueryPlan.(HQLQueryPlan.java:77)
      at org.hibernate.engine.query.HQLQueryPlan.(HQLQueryPlan.java:56)
      at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache.java:72)
      at org.hibernate.impl.AbstractSessionImpl.getHQLQueryPlan(AbstractSessionImpl.java:133)
      at org.hibernate.impl.AbstractSessionImpl.createQuery(AbstractSessionImpl.java:112)
      at org.hibernate.impl.SessionImpl.createQuery(SessionImpl.java:1623)
      at org.hibernate.ejb.AbstractEntityManagerImpl.createQuery(AbstractEntityManagerImpl.java:92)
      at org.jboss.ejb3.entity.TransactionScopedEntityManager.createQuery(TransactionScopedEntityManager.java:127)
      at com.vds.seamregistration.bean.RegisterAction.register(RegisterAction.java:29)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:112)
      at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:166)
      at org.jboss.seam.intercept.EJBInvocationContext.proceed(EJBInvocationContext.java:37)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:55)
      at org.jboss.seam.interceptors.BijectionInterceptor.bijectNonreentrantComponent(BijectionInterceptor.java:79)
      at org.jboss.seam.interceptors.BijectionInterceptor.bijectComponent(BijectionInterceptor.java:58)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
      at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
      at org.jboss.seam.interceptors.OutcomeInterceptor.interceptOutcome(OutcomeInterceptor.java:21)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
      at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
      at org.jboss.seam.interceptors.ConversationInterceptor.endOrBeginLongRunningConversation(ConversationInterceptor.java:52)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
      at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
      at org.jboss.seam.interceptors.MethodContextInterceptor.aroundInvoke(MethodContextInterceptor.java:27)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
      at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
      at org.jboss.seam.intercept.RootInterceptor.createSeamInvocationContext(RootInterceptor.java:144)
      at org.jboss.seam.intercept.RootInterceptor.invokeInContexts(RootInterceptor.java:129)
      at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:102)
      at org.jboss.seam.intercept.SessionBeanInterceptor.aroundInvoke(SessionBeanInterceptor.java:50)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:118)
      at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:126)
      at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:201)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
      at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:131)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:47)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
      at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      at org.jboss.ejb3.stateless.StatelessContainer.localInvoke(StatelessContainer.java:211)
      at org.jboss.ejb3.stateless.StatelessLocalProxy.invoke(StatelessLocalProxy.java:79)
      at $Proxy121.register(Unknown Source)
      at com.vds.seamregistration.bean.Register$$FastClassByCGLIB$$c3cee60.invoke()
      at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
      at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:45)
      at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:74)
      at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:55)
      at org.jboss.seam.intercept.RootInterceptor.createSeamInvocationContext(RootInterceptor.java:144)
      at org.jboss.seam.intercept.RootInterceptor.invokeInContexts(RootInterceptor.java:129)
      at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:102)
      at org.jboss.seam.intercept.ClientSideInterceptor.interceptInvocation(ClientSideInterceptor.java:83)
      at org.jboss.seam.intercept.ClientSideInterceptor.intercept(ClientSideInterceptor.java:52)
      at com.vds.seamregistration.bean.Register$$EnhancerByCGLIB$$9cf7a373.register()
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at com.sun.el.parser.AstValue.invoke(AstValue.java:151)
      at com.sun.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:283)
      at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)
      at com.sun.facelets.el.LegacyMethodBinding.invoke(LegacyMethodBinding.java:69)
      at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63)
      at javax.faces.component.UICommand.broadcast(UICommand.java:106)
      at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
      at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
      at org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343)
      at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.seam.servlet.SeamRedirectFilter.doFilter(SeamRedirectFilter.java:29)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:43)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
      at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
      at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      at org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
      at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
      at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
      at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
      at java.lang.Thread.run(Thread.java:595)


      Can anyone tell me how to fix this.

      Thanks in advance,
      Sandy.

        • 1. Re: Error calling action method of component
          Vladimir Ralev Newbie

          Obviously hibernate is trying to execute "select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}".

          Most likely you are using something like:

          em.createQuery("select u from User u where u.username=#{user.username}").getSingleResult();
          


          in the register method.

          You should be using something like:
          em.createQuery("select u from User u where u.username=:username").setParameter("username",user.username).getSingleResult();
          


          where user must be injected in the register bean.

          • 2. Re: Error calling action method of component
            Sandy Dee Newbie

            Even i tried your code its the same error.I'm getting an error like

            javax.servlet.ServletException: Error calling action method of component with id register:register

            • 3. Re: Error calling action method of component
              Vladimir Ralev Newbie

              Post the code of the register bean and the full stack as you did the first time.

              • 4. Re: Error calling action method of component
                Sandy Dee Newbie

                User.java is a stateless bean and Register.java is an interface and RegisterAction.java is the implementation of the interface Register.


                User.java
                ------------------
                package com.vds.seamregistration.bean;

                import static org.jboss.seam.ScopeType.SESSION;

                import javax.persistence.Entity;
                import javax.persistence.Table;
                import javax.persistence.Id;

                import org.jboss.seam.annotations.Name;
                import org.jboss.seam.annotations.Scope;

                import org.hibernate.validator.NotNull;


                @Entity
                @Name("user")
                @Scope(SESSION)
                @Table(name="users")
                public class User {

                private String username;
                private String password;
                private String name;

                public User(String username, String password, String name){
                this.username=username;
                this.password=password;
                this.name=name;
                }

                public User(){}

                @NotNull
                public String getName() {
                return name;
                }

                public void setName(String name) {
                this.name = name;
                }

                @NotNull
                public String getPassword() {
                return password;
                }

                public void setPassword(String password) {
                this.password = password;
                }

                @Id @NotNull
                public String getUsername() {
                return username;
                }

                public void setUsername(String username) {
                this.username = username;
                }

                @Override
                public String toString()
                {
                return "User(" + username + ")";
                }

                }

                Register.java
                -------------------

                package com.vds.seamregistration.bean;

                import javax.ejb.Local;

                @Local
                public interface Register {

                public String register();
                }

                RegisterAction.java
                -------------------------

                package com.vds.seamregistration.bean;



                import javax.ejb.Stateless;
                import javax.persistence.EntityManager;
                import javax.persistence.PersistenceContext;

                import org.jboss.seam.annotations.In;
                import org.jboss.seam.annotations.Logger;
                import org.jboss.seam.annotations.Name;

                import org.jboss.seam.log.Log;

                @Stateless
                @Name("register")
                public class RegisterAction implements Register{

                @In
                public User user;

                @PersistenceContext
                private EntityManager em;

                @Logger
                private static Log log;

                public String register(){

                List existing = em.createQuery("select u.username from User u where u.username=#{user.username}")
                .getResultList();

                if ( existing.size()==0 )
                {
                em.persist(user);
                log.info("Registered new user #{user.username}");
                return "/registered.jspx";
                }
                else
                {
                FacesMessages.instance().add("User #{user.username} already exists");
                return null;
                }
                }
                }

                2007-05-15 14:04:49,164 ERROR [org.jboss.seam.servlet.SeamExceptionFilter] uncaught exception
                javax.servlet.ServletException: Error calling action method of component with id register:register
                at javax.faces.webapp.FacesServlet.service(FacesServlet.java:152)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.jboss.seam.servlet.SeamRedirectFilter.doFilter(SeamRedirectFilter.java:29)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:43)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
                at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
                at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
                at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
                at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
                at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
                at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
                at org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
                at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
                at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
                at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
                at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
                at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
                at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
                at java.lang.Thread.run(Thread.java:595)
                2007-05-15 14:04:49,164 ERROR [org.jboss.seam.servlet.SeamExceptionFilter] exception root cause
                javax.faces.FacesException: Error calling action method of component with id register:register
                at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
                at javax.faces.component.UICommand.broadcast(UICommand.java:106)
                at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
                at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
                at org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343)
                at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
                at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.jboss.seam.servlet.SeamRedirectFilter.doFilter(SeamRedirectFilter.java:29)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:43)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
                at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
                at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
                at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
                at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
                at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
                at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
                at org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
                at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
                at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
                at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
                at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
                at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
                at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
                at java.lang.Thread.run(Thread.java:595)
                Caused by: javax.faces.el.EvaluationException: /register.xhtml @18,81 action="#{register.register}": javax.ejb.EJBTransactionRolledbackException: java.lang.IllegalArgumentException: org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
                at com.sun.facelets.el.LegacyMethodBinding.invoke(LegacyMethodBinding.java:73)
                at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63)
                ... 32 more
                Caused by: javax.ejb.EJBTransactionRolledbackException: java.lang.IllegalArgumentException: org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
                at org.jboss.ejb3.tx.Ejb3TxPolicy.handleInCallerTx(Ejb3TxPolicy.java:93)
                at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:130)
                at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:201)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
                at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:131)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:47)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.stateless.StatelessContainer.localInvoke(StatelessContainer.java:211)
                at org.jboss.ejb3.stateless.StatelessLocalProxy.invoke(StatelessLocalProxy.java:79)
                at $Proxy121.register(Unknown Source)
                at com.vds.seamregistration.bean.Register$$FastClassByCGLIB$$c3cee60.invoke()
                at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:45)
                at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:74)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:55)
                at org.jboss.seam.intercept.RootInterceptor.createSeamInvocationContext(RootInterceptor.java:144)
                at org.jboss.seam.intercept.RootInterceptor.invokeInContexts(RootInterceptor.java:129)
                at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:102)
                at org.jboss.seam.intercept.ClientSideInterceptor.interceptInvocation(ClientSideInterceptor.java:83)
                at org.jboss.seam.intercept.ClientSideInterceptor.intercept(ClientSideInterceptor.java:52)
                at com.vds.seamregistration.bean.Register$$EnhancerByCGLIB$$9cf7a373.register()
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at com.sun.el.parser.AstValue.invoke(AstValue.java:151)
                at com.sun.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:283)
                at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)
                at com.sun.facelets.el.LegacyMethodBinding.invoke(LegacyMethodBinding.java:69)
                ... 33 more
                Caused by: java.lang.IllegalArgumentException: org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
                at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:628)
                at org.hibernate.ejb.AbstractEntityManagerImpl.createQuery(AbstractEntityManagerImpl.java:95)
                at org.jboss.ejb3.entity.TransactionScopedEntityManager.createQuery(TransactionScopedEntityManager.java:127)
                at com.vds.seamregistration.bean.RegisterAction.register(RegisterAction.java:29)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:112)
                at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:166)
                at org.jboss.seam.intercept.EJBInvocationContext.proceed(EJBInvocationContext.java:37)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:55)
                at org.jboss.seam.interceptors.BijectionInterceptor.bijectNonreentrantComponent(BijectionInterceptor.java:79)
                at org.jboss.seam.interceptors.BijectionInterceptor.bijectComponent(BijectionInterceptor.java:58)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
                at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
                at org.jboss.seam.interceptors.OutcomeInterceptor.interceptOutcome(OutcomeInterceptor.java:21)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
                at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
                at org.jboss.seam.interceptors.ConversationInterceptor.endOrBeginLongRunningConversation(ConversationInterceptor.java:52)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
                at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
                at org.jboss.seam.interceptors.MethodContextInterceptor.aroundInvoke(MethodContextInterceptor.java:27)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
                at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
                at org.jboss.seam.intercept.RootInterceptor.createSeamInvocationContext(RootInterceptor.java:144)
                at org.jboss.seam.intercept.RootInterceptor.invokeInContexts(RootInterceptor.java:129)
                at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:102)
                at org.jboss.seam.intercept.SessionBeanInterceptor.aroundInvoke(SessionBeanInterceptor.java:50)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:118)
                at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:126)
                ... 68 more
                Caused by: org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
                at org.hibernate.hql.ast.QueryTranslatorImpl.doCompile(QueryTranslatorImpl.java:204)
                at org.hibernate.hql.ast.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:111)
                at org.hibernate.engine.query.HQLQueryPlan.(HQLQueryPlan.java:77)
                at org.hibernate.engine.query.HQLQueryPlan.(HQLQueryPlan.java:56)
                at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache.java:72)
                at org.hibernate.impl.AbstractSessionImpl.getHQLQueryPlan(AbstractSessionImpl.java:133)
                at org.hibernate.impl.AbstractSessionImpl.createQuery(AbstractSessionImpl.java:112)
                at org.hibernate.impl.SessionImpl.createQuery(SessionImpl.java:1623)
                at org.hibernate.ejb.AbstractEntityManagerImpl.createQuery(AbstractEntityManagerImpl.java:92)
                ... 127 more
                2007-05-15 14:04:49,179 DEBUG [org.jboss.seam.util.Naming] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory, java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
                2007-05-15 14:04:49,179 DEBUG [org.jboss.seam.servlet.SeamExceptionFilter] ending request
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.exceptions
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.exceptions
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.exceptions
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.core.Events] Processing event:org.jboss.seam.preSetVariable.org.jboss.seam.core.exceptions
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.core.Events] Processing event:org.jboss.seam.postSetVariable.org.jboss.seam.core.exceptions
                2007-05-15 14:04:49,195 INFO [org.jboss.seam.core.Exceptions] reading exception mappings from /WEB-INF/pages.xml
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.util.DTDEntityResolver] trying to resolve system-id [http://jboss.com/products/seam/pages-1.1.dtd]
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.util.DTDEntityResolver] recognized Seam namespace; attempting to resolve on classpath under org/jboss/seam/
                2007-05-15 14:04:49,195 DEBUG [org.jboss.seam.util.DTDEntityResolver] located [http://jboss.com/products/seam/pages-1.1.dtd] in classpath
                2007-05-15 14:04:49,210 DEBUG [org.jboss.mx.loading.RepositoryClassLoader] setRepository, repository=org.jboss.mx.loading.HeirarchicalLoaderRepository3@16e588e, cl=org.jboss.mx.loading.HeirarchicalLoaderRepository3$CacheClassLoader@32835b{ url=null ,addedOrder=0}
                2007-05-15 14:04:49,210 DEBUG [org.jboss.mx.loading.RepositoryClassLoader] setRepository, repository=org.jboss.mx.loading.HeirarchicalLoaderRepository3@16e588e, cl=org.jboss.mx.loading.HeirarchicalLoaderRepository3$CacheClassLoader@4df9a0{ url=null ,addedOrder=0}
                2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
                2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
                2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
                2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] instantiating Seam component: org.jboss.seam.core.events
                2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] initializing new instance of: org.jboss.seam.core.events
                2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.Component] done initializing: org.jboss.seam.core.events
                2007-05-15 14:04:49,210 DEBUG [org.jboss.seam.core.Events] Processing event:org.jboss.seam.postCreate.org.jboss.seam.core.exceptions
                2007-05-15 14:04:49,210 ERROR [org.jboss.seam.exceptions.DebugPageHandler] redirecting to debug page
                org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
                at org.hibernate.hql.ast.QueryTranslatorImpl.doCompile(QueryTranslatorImpl.java:204)
                at org.hibernate.hql.ast.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:111)
                at org.hibernate.engine.query.HQLQueryPlan.(HQLQueryPlan.java:77)
                at org.hibernate.engine.query.HQLQueryPlan.(HQLQueryPlan.java:56)
                at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache.java:72)
                at org.hibernate.impl.AbstractSessionImpl.getHQLQueryPlan(AbstractSessionImpl.java:133)
                at org.hibernate.impl.AbstractSessionImpl.createQuery(AbstractSessionImpl.java:112)
                at org.hibernate.impl.SessionImpl.createQuery(SessionImpl.java:1623)
                at org.hibernate.ejb.AbstractEntityManagerImpl.createQuery(AbstractEntityManagerImpl.java:92)
                at org.jboss.ejb3.entity.TransactionScopedEntityManager.createQuery(TransactionScopedEntityManager.java:127)
                at com.vds.seamregistration.bean.RegisterAction.register(RegisterAction.java:29)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:112)
                at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:166)
                at org.jboss.seam.intercept.EJBInvocationContext.proceed(EJBInvocationContext.java:37)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:55)
                at org.jboss.seam.interceptors.BijectionInterceptor.bijectNonreentrantComponent(BijectionInterceptor.java:79)
                at org.jboss.seam.interceptors.BijectionInterceptor.bijectComponent(BijectionInterceptor.java:58)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
                at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
                at org.jboss.seam.interceptors.OutcomeInterceptor.interceptOutcome(OutcomeInterceptor.java:21)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
                at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
                at org.jboss.seam.interceptors.ConversationInterceptor.endOrBeginLongRunningConversation(ConversationInterceptor.java:52)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
                at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
                at org.jboss.seam.interceptors.MethodContextInterceptor.aroundInvoke(MethodContextInterceptor.java:27)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
                at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
                at org.jboss.seam.intercept.RootInterceptor.createSeamInvocationContext(RootInterceptor.java:144)
                at org.jboss.seam.intercept.RootInterceptor.invokeInContexts(RootInterceptor.java:129)
                at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:102)
                at org.jboss.seam.intercept.SessionBeanInterceptor.aroundInvoke(SessionBeanInterceptor.java:50)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:118)
                at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:126)
                at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:201)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
                at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:131)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:47)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
                at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
                at org.jboss.ejb3.stateless.StatelessContainer.localInvoke(StatelessContainer.java:211)
                at org.jboss.ejb3.stateless.StatelessLocalProxy.invoke(StatelessLocalProxy.java:79)
                at $Proxy121.register(Unknown Source)
                at com.vds.seamregistration.bean.Register$$FastClassByCGLIB$$c3cee60.invoke()
                at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:45)
                at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:74)
                at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:55)
                at org.jboss.seam.intercept.RootInterceptor.createSeamInvocationContext(RootInterceptor.java:144)
                at org.jboss.seam.intercept.RootInterceptor.invokeInContexts(RootInterceptor.java:129)
                at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:102)
                at org.jboss.seam.intercept.ClientSideInterceptor.interceptInvocation(ClientSideInterceptor.java:83)
                at org.jboss.seam.intercept.ClientSideInterceptor.intercept(ClientSideInterceptor.java:52)
                at com.vds.seamregistration.bean.Register$$EnhancerByCGLIB$$9cf7a373.register()
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at com.sun.el.parser.AstValue.invoke(AstValue.java:151)
                at com.sun.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:283)
                at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)
                at com.sun.facelets.el.LegacyMethodBinding.invoke(LegacyMethodBinding.java:69)
                at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63)
                at javax.faces.component.UICommand.broadcast(UICommand.java:106)
                at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
                at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
                at org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343)
                at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
                at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.jboss.seam.servlet.SeamRedirectFilter.doFilter(SeamRedirectFilter.java:29)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:43)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
                at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
                at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
                at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
                at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
                at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
                at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
                at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
                at org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
                at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
                at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
                at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
                at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
                at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
                at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
                at java.lang.Thread.run(Thread.java:595)

                • 5. Re: Error calling action method of component
                  Vladimir Ralev Newbie

                  What happens when you use:

                   List existing = em.createQuery("select u.username from User u where u.username=:uname").setParameter("uname",user.username)
                  .getResultList();
                  


                  • 6. Re: Error calling action method of component
                    Sandy Dee Newbie

                    Same error is been displayed

                    • 7. Re: Error calling action method of component
                      Vladimir Ralev Newbie

                      Is the whole stacktrace the same? Are you sure the modified files are being rebuilt and redeployed correctly?

                      • 8. Re: Error calling action method of component
                        Sandy Dee Newbie

                        ya i rebuilt the application and redeployed it.still i get the same error like
                        [org.jboss.seam.servlet.SeamExceptionFilter] uncaught exception
                        javax.servlet.ServletException: Error calling action method of component with id register:register

                        • 9. Re: Error calling action method of component
                          Vladimir Ralev Newbie

                          [org.jboss.seam.servlet.SeamExceptionFilter] uncaught exception
                          javax.servlet.ServletException: Error calling action method of component with id register:register

                          is too generic. I am asking for the full stack to see what is causing it. With you original code it was

                          Caused by: org.hibernate.QueryException: unexpected char: '#' [select u.username from com.vds.seamregistration.bean.User u where u.username=#{user.username}]
                          

                          The cause should be different now.

                          • 10. Re: Error calling action method of component
                            Sandy Dee Newbie

                            If i'm using the code which you have given then i'm unable to complie the class its showing an error like
                            "The field User.username not visisble"

                            • 11. Re: Error calling action method of component
                              Vladimir Ralev Newbie

                              Well, use getter:

                               List existing = em.createQuery("select u.username from User u where u.username=:uname").setParameter("uname", user.getUsername())
                              .getResultList();