使用生成工具生成代码报错

Blade 未结 4 1686
lianfc
lianfc 2022-09-20 08:04

一、该问题的重现步骤是什么?

  1. bladex cloud3.0.1版本,打开研发工具-->数据模型设计-->选择数据源为oracle时报如下错误,数据库没配置表直接选择oracle也是报错,用oracle6、8版本的驱动jar包试过,都会出错,本地oracle用19c和11g都一样。


022-09-20 07:58:55.235  WARN 36124 --- [  XNIO-1 task-2] c.b.m.g.jdbc.DatabaseMetaDataWrapper     : 获取IS_AUTOINCREMENT出现异常:


java.sql.SQLException: 列名无效

at oracle.jdbc.driver.OracleStatement.getColumnIndex(OracleStatement.java:3711)

at oracle.jdbc.driver.OracleResultSetImpl.findColumn(OracleResultSetImpl.java:2763)

at oracle.jdbc.driver.OracleResultSet.getString(OracleResultSet.java:494)

at com.baomidou.mybatisplus.generator.jdbc.DatabaseMetaDataWrapper.getColumnsInfo(DatabaseMetaDataWrapper.java:115)

at com.baomidou.mybatisplus.generator.jdbc.DatabaseMetaDataWrapper.getColumnsInfo(DatabaseMetaDataWrapper.java:78)

at com.baomidou.mybatisplus.generator.query.DefaultQuery.getColumnsInfo(DefaultQuery.java:124)

at com.baomidou.mybatisplus.generator.query.DefaultQuery.convertTableFields(DefaultQuery.java:95)

at java.util.ArrayList.forEach(ArrayList.java:1259)

at com.baomidou.mybatisplus.generator.query.DefaultQuery.queryTables(DefaultQuery.java:83)

at com.baomidou.mybatisplus.generator.config.builder.ConfigBuilder.getTableInfoList(ConfigBuilder.java:152)

at org.springblade.develop.controller.ModelController.tableList(ModelController.java:149)

at org.springblade.develop.controller.ModelController$$FastClassBySpringCGLIB$$53694a51.invoke()

at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218)

at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:793)

at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)

at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:763)

at org.springframework.aop.aspectj.MethodInvocationProceedingJoinPoint.proceed(MethodInvocationProceedingJoinPoint.java:89)

at org.springblade.core.log.aspect.RequestLogAspect.aroundApi(RequestLogAspect.java:112)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:498)

at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:634)

at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:624)

at org.springframework.aop.aspectj.AspectJAroundAdvice.invoke(AspectJAroundAdvice.java:72)

at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:175)

at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:763)

at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:97)

at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)

at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:763)

at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708)

at org.springblade.develop.controller.ModelController$$EnhancerBySpringCGLIB$$dd0f43e3.tableList()

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:498)

at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:205)

at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:150)

at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:117)

at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:895)

at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:808)

at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87)

at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1067)

at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:963)

at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006)

at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:898)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:497)

at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:584)

image.png


2. 

3.


二、你期待的结果是什么?实际看到的又是什么?


三、你正在使用的是什么产品,什么版本?在什么操作系统上?


四、请提供详细的错误堆栈信息,这很重要。


五、若有更多详细信息,请在下面提供。

4条回答
提交回复