NutzCN Logo
问答 nutzwk项目将mysql链接改为oracle链接,项目初始化错误
发布于 2308天前 作者 qq_cff0990a 1614 次浏览 复制 上一个帖子 下一个帖子
标签: nutzwk
org.nutz.dao.DaoException: !Nutz SQL Error: 'CREATE TABLE sys_user(
id VARCHAR2(32) primary key ,
loginname VARCHAR2(120),
password VARCHAR2(100),
salt VARCHAR2(50),
nickname VARCHAR2(100),
online char(1) check (online in(0,1)),
disabled char(1) check (disabled in(0,1)),
email VARCHAR2(255),
loginAt NUMBER(5),
loginIp VARCHAR2(255),
loginCount NUMBER(5),
customMenu VARCHAR2(255),
loginTheme VARCHAR2(100),
loginSidebar char(1) check (loginSidebar in(0,1)),
loginBoxed char(1) check (loginBoxed in(0,1)),
loginScroll char(1) check (loginScroll in(0,1)),
unitid VARCHAR2(32),
opBy VARCHAR2(32),
opAt NUMBER(5),
delFlag char(1) check (delFlag in(0,1)))'
PreparedStatement: 
'CREATE TABLE sys_user(
id VARCHAR2(32) primary key ,
loginname VARCHAR2(120),
password VARCHAR2(100),
salt VARCHAR2(50),
nickname VARCHAR2(100),
online char(1) check (online in(0,1)),
disabled char(1) check (disabled in(0,1)),
email VARCHAR2(255),
loginAt NUMBER(5),
loginIp VARCHAR2(255),
loginCount NUMBER(5),
customMenu VARCHAR2(255),
loginTheme VARCHAR2(100),
loginSidebar char(1) check (loginSidebar in(0,1)),
loginBoxed char(1) check (loginBoxed in(0,1)),
loginScroll char(1) check (loginScroll in(0,1)),
unitid VARCHAR2(32),
opBy VARCHAR2(32),
opAt NUMBER(5),
delFlag char(1) check (delFlag in(0,1)))'
CaseMessage=ORA-00904: : 标识符无效
2018-08-28 13:39:00,345 org.nutz.mvc.impl.NutLoading.load(NutLoading.java:141) INFO  - Nutz.Mvc[nutz] is up in 2329ms
2018-08-28 13:39:00,345 org.nutz.mvc.NutFilter._init(NutFilter.java:113) INFO  - exclusionsPrefix  = ^(/assets/|/druid/|/upload/|/apidoc/)

	at org.nutz.dao.impl.sql.run.NutDaoExecutor.exec(NutDaoExecutor.java:104)
	at org.nutz.plugins.cache.dao.CachedNutDaoExecutor.exec(CachedNutDaoExecutor.java:187)
	at org.nutz.dao.DaoInterceptorChain.doChain(DaoInterceptorChain.java:66)
	at org.nutz.dao.impl.interceptor.DaoLogInterceptor.filter(DaoLogInterceptor.java:22)
	at org.nutz.dao.DaoInterceptorChain.doChain(DaoInterceptorChain.java:64)
	at org.nutz.dao.DaoInterceptorChain.invoke(DaoInterceptorChain.java:139)
	at org.nutz.dao.impl.sql.run.NutDaoRunner.runCallback(NutDaoRunner.java:158)
	at org.nutz.dao.impl.sql.run.NutDaoRunner._runWithTransaction(NutDaoRunner.java:104)
	at org.nutz.dao.impl.sql.run.NutDaoRunner._run(NutDaoRunner.java:88)
	at org.nutz.dao.impl.sql.run.NutDaoRunner$1.run(NutDaoRunner.java:74)
	at org.nutz.trans.Trans.exec(Trans.java:174)
	at org.nutz.dao.impl.sql.run.NutDaoRunner.run(NutDaoRunner.java:72)
	at org.nutz.dao.impl.DaoSupport.run(DaoSupport.java:240)
	at org.nutz.dao.impl.DaoSupport._exec(DaoSupport.java:248)
	at org.nutz.dao.impl.DaoSupport.execute(DaoSupport.java:236)
	at org.nutz.dao.impl.jdbc.oracle.OracleJdbcExpert.createEntity(OracleJdbcExpert.java:137)
	at org.nutz.dao.impl.EntityHolder.reloadEntity(EntityHolder.java:86)
	at org.nutz.dao.impl.NutDao.create(NutDao.java:784)
	at org.nutz.dao.util.Daos.createTablesInPackage(Daos.java:539)
	at cn.wizzer.common.core.Setup.initSysData(Setup.java:135)
	at cn.wizzer.common.core.Setup.init(Setup.java:44)
	at org.nutz.mvc.impl.NutLoading.evalSetup(NutLoading.java:277)
	at org.nutz.mvc.impl.NutLoading.load(NutLoading.java:121)
	at org.nutz.mvc.ActionHandler.<init>(ActionHandler.java:19)
	at org.nutz.mvc.NutFilter._init(NutFilter.java:87)
	at org.nutz.mvc.NutFilter.init(NutFilter.java:65)
	at org.eclipse.jetty.servlet.FilterHolder.initialize(FilterHolder.java:138)
	at org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:852)
	at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:298)
	at org.eclipse.jetty.webapp.WebAppContext.startWebapp(WebAppContext.java:1349)
	at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1342)
	at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:741)
	at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:505)
	at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
	at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:132)
	at org.eclipse.jetty.server.Server.start(Server.java:387)
	at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:114)
	at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:61)
	at org.eclipse.jetty.server.Server.doStart(Server.java:354)
	at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
	at org.nutz.web.WebServer.run(WebServer.java:95)
	at org.nutz.web.WebLauncher.start(WebLauncher.java:55)
	at org.nutz.web.WebLauncher.main(WebLauncher.java:25)
Caused by: java.sql.SQLSyntaxErrorException: ORA-00904: : 标识符无效

	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:439)
	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:395)
	at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:802)
	at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:436)
	at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:186)
	at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:521)
	at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:194)
	at oracle.jdbc.driver.T4CStatement.executeForRows(T4CStatement.java:1000)
	at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1307)
	at oracle.jdbc.driver.OracleStatement.executeInternal(OracleStatement.java:1882)
	at oracle.jdbc.driver.OracleStatement.execute(OracleStatement.java:1847)
	at oracle.jdbc.driver.OracleStatementWrapper.execute(OracleStatementWrapper.java:301)
	at com.alibaba.druid.filter.FilterChainImpl.statement_execute(FilterChainImpl.java:2489)
	at com.alibaba.druid.filter.FilterAdapter.statement_execute(FilterAdapter.java:2451)
	at com.alibaba.druid.filter.FilterEventAdapter.statement_execute(FilterEventAdapter.java:188)
	at com.alibaba.druid.filter.FilterChainImpl.statement_execute(FilterChainImpl.java:2487)
	at com.alibaba.druid.proxy.jdbc.StatementProxyImpl.execute(StatementProxyImpl.java:137)
	at com.alibaba.druid.pool.DruidPooledStatement.execute(DruidPooledStatement.java:416)
	at org.nutz.dao.impl.sql.run.NutDaoExecutor._runStatement(NutDaoExecutor.java:357)
	at org.nutz.dao.impl.sql.run.NutDaoExecutor.exec(NutDaoExecutor.java:60)
	... 42 more

貌似是初始化有oracle关键字的问题,但查了半天没找到如何解决的方法

13 回复

oracle、达梦都是测过的啊..

@Wizzercn 呃,刚用nutz,不懂啊

刚用的?用4.x或者5.x啦

@wendal 刚改了版本(重新install,不知道这样行不行)

<groupId>cn.wizzer</groupId>
    <artifactId>nutzwk</artifactId>
    <packaging>war</packaging>
    <version>4.2.0</version>
    <name>NutzWk</name>
    <url>http://www.wizzer.cn</url>

之后重新运行,还是之前的错误

oracle什么版本

改了版本是什么意思?

@wendal oracle 11.2.0.1.0
改版本是从之前的nutzwk3.2 改到 4.2

你指的是改个版本号??

@wendal 那具体怎么操作啊?
我的问题主要是:1.改完oracle链接后通过bean生成sql语句错误(应该是关键字问题),该如何解决
2. 您说的改版本升级到4.x以上,是否是3.x的版本问题
3.我通过pom更改版本号,重新clean 后install,之后改如何做才能把nutzwk改到4.x版本
刚接触nutz框架不久很多不懂,麻烦帮我解答,万分感谢

我的意思是下载4.x版的nutzwk

@wendal 通过maven重新下载的nutzwk算是重新下载吧。。。。

添加回复
请先登陆
回到顶部