2018-05-21 15:12:26,000 INFO [org.springframework.flex.servlet.MessageBrokerHandlerAdapter] - Channel endpoint my-amf received request.
2018-05-21 15:12:26,062 INFO [org.springframework.flex.servlet.MessageBrokerHandlerAdapter] - Channel endpoint my-amf received request.
Hibernate:
SELECT
COUNT(a.id)
FROM
Bus_Asset a
LEFT JOIN
Bsc_AssetType b
ON a.typeid = b.id
LEFT JOIN
Bsc_Organ c
ON a.organid = c.id
LEFT JOIN
Acc_User d
ON a.whsemgrid = d.id
LEFT JOIN
Bsc_WareHouse e
ON a.whseid = e.id
LEFT JOIN
Bsc_ChngMthd f
ON a.chngmthdid = f.id
LEFT JOIN
(
SELECT
h.chngmthdid,
i.assetid,
j.name
FROM
Bus_AssetReduce h
LEFT JOIN
Bus_AssetReduceItem i
ON h.id = i.fthrId
LEFT JOIN
Bsc_ChngMthd j
ON h.chngmthdid = j.id
) x
ON a.id = x.assetid
LEFT JOIN
Bsc_Status k
ON a.statusid = k.id
WHERE
1 = 1
AND a.state = ?
Hibernate:
SELECT
top 30 a.id AS ID,
b.name AS TYPENAME,
a.code AS CODE,
a.name AS ASSETNAME,
a.spenmdl AS SPENMDL,
a.msrunit AS MSRUNIT,
a.cnt AS CNT,
a.amt AS AMT,
a.XACTDT AS XACTDT,
a.deadln AS DEADLN,
c.name AS ORGNAME,
d.name AS MGRNAME,
e.name AS WHNAME,
a.memo AS MEMO
FROM
Bus_Asset a
LEFT JOIN
Bsc_AssetType b
ON a.typeid = b.id
LEFT JOIN
Bsc_Organ c
ON a.organid = c.id
LEFT JOIN
Acc_User d
ON a.whsemgrid = d.id
LEFT JOIN
Bsc_WareHouse e
ON a.whseid = e.id
LEFT JOIN
Bsc_ChngMthd f
ON a.chngmthdid = f.id
LEFT JOIN
(
SELECT
h.chngmthdid,
i.assetid,
j.name
FROM
Bus_AssetReduce h
LEFT JOIN
Bus_AssetReduceItem i
ON h.id = i.fthrId
LEFT JOIN
Bsc_ChngMthd j
ON h.chngmthdid = j.id
) x
ON a.id = x.assetid
LEFT JOIN
Bsc_Status k
ON a.statusid = k.id
WHERE
1 = 1
AND a.state = ?
ORDER BY
a.typeid,
a.code
2018-05-21 15:12:28,656 ERROR [ce.pub.exception.FlexExceptionTranslator] - org.hibernate.MappingException: No Dialect mapping for JDBC type: -9
org.hibernate.MappingException: No Dialect mapping for JDBC type: -9
at org.hibernate.dialect.TypeNames.get(TypeNames.java:79)
at org.hibernate.dialect.TypeNames.get(TypeNames.java:104)
at org.hibernate.dialect.Dialect.getHibernateTypeName(Dialect.java:393)
at org.hibernate.loader.custom.CustomLoader$Metadata.getHibernateType(CustomLoader.java:582)
at org.hibernate.loader.custom.CustomLoader$ScalarResultColumnProcessor.performDiscovery(CustomLoader.java:508)
at org.hibernate.loader.custom.CustomLoader.autoDiscoverTypes(CustomLoader.java:524)
at org.hibernate.loader.Loader.getResultSet(Loader.java:1821)
at org.hibernate.loader.Loader.doQuery(Loader.java:697)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:259)
at org.hibernate.loader.Loader.doList(Loader.java:2232)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2129)
at org.hibernate.loader.Loader.list(Loader.java:2124)
at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:312)
at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1723)
at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:165)
at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:175)
at ce.assets.report.AstInfoDAO.load(AstInfoDAO.java:68)
at ce.assets.report.AstInfoRpt.doLoad(AstInfoRpt.java:39)
at ce.assets.report.AstInfoRpt$$FastClassByCGLIB$$b008b101.invoke(<generated>)
at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
at org.springframework.aop.framework.Cglib2AopProxy$CglibMethodInvocation.invokeJoinpoint(Cglib2AopProxy.java:692)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at org.springframework.aop.framework.adapter.MethodBeforeAdviceInterceptor.invoke(MethodBeforeAdviceInterceptor.java:50)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:108)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.intercept(Cglib2AopProxy.java:625)
at ce.assets.report.AstInfoRpt$$EnhancerByCGLIB$$dc7437a8.doLoad(<generated>)
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:597)
at flex.messaging.services.remoting.adapters.JavaAdapter.invoke(JavaAdapter.java:421)
at flex.messaging.services.RemotingService.serviceMessage(RemotingService.java:183)
at flex.messaging.MessageBroker.routeMessageToService(MessageBroker.java:1503)
at flex.messaging.endpoints.AbstractEndpoint.serviceMessage(AbstractEndpoint.java:884)
at flex.messaging.endpoints.AbstractEndpoint$$FastClassByCGLIB$$1a3ef066.invoke(<generated>)
at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
at org.springframework.aop.framework.Cglib2AopProxy$CglibMethodInvocation.invokeJoinpoint(Cglib2AopProxy.java:692)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at org.springframework.flex.core.MessageInterceptionAdvice.invoke(MessageInterceptionAdvice.java:66)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.adapter.ThrowsAdviceInterceptor.invoke(ThrowsAdviceInterceptor.java:124)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.Cglib2AopProxy$FixedChainStaticTargetInterceptor.intercept(Cglib2AopProxy.java:576)
at flex.messaging.endpoints.AMFEndpoint$$EnhancerByCGLIB$$9238b4b4.serviceMessage(<generated>)
at flex.messaging.endpoints.amf.MessageBrokerFilter.invoke(MessageBrokerFilter.java:121)
at flex.messaging.endpoints.amf.LegacyFilter.invoke(LegacyFilter.java:158)
at flex.messaging.endpoints.amf.SessionFilter.invoke(SessionFilter.java:44)
at flex.messaging.endpoints.amf.BatchProcessFilter.invoke(BatchProcessFilter.java:67)
at flex.messaging.endpoints.amf.SerializationFilter.invoke(SerializationFilter.java:146)
at flex.messaging.endpoints.BaseHTTPEndpoint.service(BaseHTTPEndpoint.java:278)
at flex.messaging.endpoints.AMFEndpoint$$EnhancerByCGLIB$$9238b4b4.service(<generated>)
at org.springframework.flex.servlet.MessageBrokerHandlerAdapter.handle(MessageBrokerHandlerAdapter.java:101)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:771)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:716)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:647)
at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:563)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:643)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:723)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:861)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:620)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Thread.java:662)
============================================================================
本文MS SERVER 2000数据库,由于之前MS SERVER 2008数据库,导致驱动程序JAR版本不对造成的。
同理ORACLE也是~ ~ ~
今天弄固定资产系统的时候发现。。。。。太久没弄了。。。
============================================================================
1:准确使用hibernate对应的数据库方言
2:准确使用数据库驱动程序