org.hibernate.exception.GenericJDBCException

Incorrect syntax near the keyword 'as'.

Samebug tips0

There are no available Samebug tips for this exception. If you know how to solve this issue, help other users by writing a short tip.

Don't give up yet. Paste your full stack trace to get a solution.

Solutions on the web22

  • via Apereo Issues by Dan McCallum, 1 year ago
    Incorrect syntax near the keyword 'as'.
  • via Apereo Issues by Jason Elwood, 1 year ago
    Incorrect syntax near the keyword 'as'.
  • via Apereo Issues by Dan McCallum, 1 year ago
    Incorrect syntax near the keyword 'as'.
  • Stack trace

    • org.hibernate.exception.GenericJDBCException: Incorrect syntax near the keyword 'as'. at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:52)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:125)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:110)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.engine.jdbc.internal.proxy.AbstractStatementProxyHandler.continueInvocation(AbstractStatementProxyHandler.java:129)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.engine.jdbc.internal.proxy.AbstractProxyHandler.invoke(AbstractProxyHandler.java:81)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at com.sun.proxy.$Proxy278.executeQuery(Unknown Source)[na:na] at org.hibernate.loader.Loader.getResultSet(Loader.java:1978)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.loader.Loader.doQuery(Loader.java:829)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:289)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.loader.Loader.doList(Loader.java:2463)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.loader.Loader.doList(Loader.java:2449)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2279)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.loader.Loader.list(Loader.java:2274)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.loader.criteria.CriteriaLoader.list(CriteriaLoader.java:122)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.internal.SessionImpl.list(SessionImpl.java:1483)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.hibernate.internal.CriteriaImpl.list(CriteriaImpl.java:374)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] at org.jasig.ssp.dao.AbstractDao.processCriteriaWithSortingAndPaging(AbstractDao.java:134)[AbstractDao.class:na] at org.jasig.ssp.dao.AbstractDao.processCriteriaWithStatusSortingAndPaging(AbstractDao.java:149)[AbstractDao.class:na] at org.jasig.ssp.dao.reference.AbstractReferenceAuditableCrudDao.getAll(AbstractReferenceAuditableCrudDao.java:54)[AbstractReferenceAuditableCrudDao.class:na] at org.jasig.ssp.service.AbstractAuditableCrudService.getAll(AbstractAuditableCrudService.java:59)[AbstractAuditableCrudService.class:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[na:1.7.0_67] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)[na:1.7.0_67] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)[na:1.7.0_67] at java.lang.reflect.Method.invoke(Unknown Source)[na:1.7.0_67] at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)[spring-aop-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)[spring-aop-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)[spring-aop-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:96)[spring-tx-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:260)[spring-tx-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:94)[spring-tx-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)[spring-aop-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)[spring-aop-3.2.8.RELEASE.jar:3.2.8.RELEASE] at com.sun.proxy.$Proxy479.getAll(Unknown Source)[na:na] at org.jasig.ssp.web.api.reference.AbstractAuditableReferenceController.getAll(AbstractAuditableReferenceController.java:144)[AbstractAuditableReferenceController.class:na] at org.jasig.ssp.web.api.reference.AbstractAuditableReferenceController$$FastClassBySpringCGLIB$$22e23a41.invoke(<generated>)[spring-core-3.2.8.RELEASE.jar:na] at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204)[spring-core-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:700)[spring-aop-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)[spring-aop-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.security.access.intercept.aopalliance.MethodSecurityInterceptor.invoke(MethodSecurityInterceptor.java:64)[spring-security-core-3.2.3.RELEASE.jar:3.2.3.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)[spring-aop-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:633)[spring-aop-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.jasig.ssp.web.api.reference.SuccessIndicatorController$$EnhancerBySpringCGLIB$$60796a87.getAll(<generated>)[spring-core-3.2.8.RELEASE.jar:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[na:1.7.0_67] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)[na:1.7.0_67] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)[na:1.7.0_67] at java.lang.reflect.Method.invoke(Unknown Source)[na:1.7.0_67] at org.springframework.web.method.support.InvocableHandlerMethod.invoke(InvocableHandlerMethod.java:215)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:132)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:104)[spring-webmvc-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandleMethod(RequestMappingHandlerAdapter.java:745)[spring-webmvc-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:686)[spring-webmvc-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:80)[spring-webmvc-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:925)[spring-webmvc-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856)[spring-webmvc-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:953)[spring-webmvc-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:844)[spring-webmvc-3.2.8.RELEASE.jar:3.2.8.RELEASE] at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)[servlet-api.jar:na] at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:829)[spring-webmvc-3.2.8.RELEASE.jar:3.2.8.RELEASE] at javax.servlet.http.HttpServlet.service(HttpServlet.java:723)[servlet-api.jar:na] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)[catalina.jar:6.0.37] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:6.0.37] at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:164)[urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)[urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)[urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417)[urlrewritefilter-3.1.0.jar:3.1.0] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:6.0.37] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:6.0.37] at org.jasig.ssp.security.uportal.KeepSessionAliveFilter.doFilter(KeepSessionAliveFilter.java:116)[KeepSessionAliveFilter.class:na] at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:343)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:260)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:6.0.37] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:6.0.37] at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:330)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:118)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:84)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:342)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:113)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:342)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:113)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:342)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:54)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:342)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:45)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:342)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.jasig.ssp.security.uportal.UPortalPreAuthenticatedProcessingFilter.doFilter(UPortalPreAuthenticatedProcessingFilter.java:98)[UPortalPreAuthenticatedProcessingFilter.class:na] at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:342)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.oauth2.provider.authentication.OAuth2AuthenticationProcessingFilter.doFilter(OAuth2AuthenticationProcessingFilter.java:131)[spring-security-oauth2-1.0.5.RELEASE.jar:na] at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:342)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:87)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:342)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:192)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:160)[spring-security-web-3.1.3.RELEASE.jar:3.1.3.RELEASE] at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:343)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:260)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:6.0.37] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:6.0.37] at org.jasig.ssp.security.uportal.RequestAndResponseAccessFilter.doFilter(RequestAndResponseAccessFilter.java:61)[RequestAndResponseAccessFilter.class:na] at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:343)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:260)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:6.0.37] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:6.0.37] at org.jasig.ssp.security.RequestCleanupServletFilter.doFilter(RequestCleanupServletFilter.java:40)[RequestCleanupServletFilter.class:na] at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:343)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:260)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:6.0.37] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:6.0.37] at org.springframework.orm.hibernate4.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:151)[spring-orm-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:6.0.37] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:6.0.37] at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)[spring-web-3.2.8.RELEASE.jar:3.2.8.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:6.0.37] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:6.0.37] at ch.qos.logback.classic.helpers.MDCInsertingServletFilter.doFilter(MDCInsertingServletFilter.java:51)[logback-classic-1.0.0.jar:na] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:6.0.37] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:6.0.37] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)[catalina.jar:6.0.37] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)[catalina.jar:6.0.37] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)[catalina.jar:6.0.37] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)[catalina.jar:6.0.37] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)[catalina.jar:6.0.37] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)[catalina.jar:6.0.37] at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:861)[tomcat-coyote.jar:6.0.37] at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:606)[tomcat-coyote.jar:6.0.37] at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)[tomcat-coyote.jar:6.0.37] at java.lang.Thread.run(Unknown Source)[na:1.7.0_67] Caused by: java.sql.SQLException: Incorrect syntax near the keyword 'as'. at net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:368)[jtds-1.2.4.jar:1.2.4] at net.sourceforge.jtds.jdbc.TdsCore.tdsErrorToken(TdsCore.java:2820)[jtds-1.2.4.jar:1.2.4] at net.sourceforge.jtds.jdbc.TdsCore.nextToken(TdsCore.java:2258)[jtds-1.2.4.jar:1.2.4] at net.sourceforge.jtds.jdbc.TdsCore.getMoreResults(TdsCore.java:632)[jtds-1.2.4.jar:1.2.4] at net.sourceforge.jtds.jdbc.JtdsStatement.executeSQLQuery(JtdsStatement.java:477)[jtds-1.2.4.jar:1.2.4] at net.sourceforge.jtds.jdbc.JtdsPreparedStatement.executeQuery(JtdsPreparedStatement.java:778)[jtds-1.2.4.jar:1.2.4] at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96)[commons-dbcp-1.4.jar:1.4] at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96)[commons-dbcp-1.4.jar:1.4] at sun.reflect.GeneratedMethodAccessor195.invoke(Unknown Source)[na:na] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)[na:1.7.0_67] at java.lang.reflect.Method.invoke(Unknown Source)[na:1.7.0_67] at org.hibernate.engine.jdbc.internal.proxy.AbstractStatementProxyHandler.continueInvocation(AbstractStatementProxyHandler.java:122)[hibernate-core-4.0.1.Final.jar:4.0.1.Final] ... 123 more

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    Unknown user
    Once, 1 year ago
    2 times, 1 month ago
    Unknown user
    Once, 5 months ago
    Unknown user
    Once, 10 months ago
    Once, 10 months ago
    24 more bugmates