起步软件技术论坛
搜索
 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 2681|回复: 2

[结贴] excel导入报错,版主来帮忙看下,急

[复制链接]

16

主题

35

帖子

93

积分

初级会员

Rank: 2

积分
93
QQ
发表于 2013-10-30 15:43:19 | 显示全部楼层 |阅读模式
版本: X5.2.5 小版本号:
数据库: MySQL 服务器操作系统: Windows 应用服务器: Tomcat
客户端操作系统: Windows 7 浏览器: IE7
imp.mapping.xml文件内容:
<?xml version="1.0" encoding="UTF-8"?>
<mapping>
        <default-config>
                <sheet all="true" />
                <row all="true" />
        </default-config>
        <concept name="CO_Test">
                <relation name="ftest" cell-number="1"/>
                              
        </concept>
</mapping>
选择上传文件后报错:
导入excel失败! 加载excel导入映射文件失败!
详细信息:

com.justep.model.exception.ModelException: java.lang.reflect.InvocationTargetException
at com.justep.system.action.Engine.invokeActions(Unknown Source)
at com.justep.business.server.BusinessServer.doAction(Unknown Source)
at com.justep.business.server.BusinessServer.doExcute(Unknown Source)
at com.justep.business.server.BusinessServer.excute(Unknown Source)
at com.justep.business.server.BusinessServerServlet.execService(Unknown Source)
at com.justep.business.server.BusinessServerServlet.service(Unknown Source)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at com.justep.x.bs.BusinessServerServlet.service(Unknown Source)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
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:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:857)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Thread.java:595)
Caused by: java.lang.reflect.InvocationTargetException
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:592)
at com.justep.system.action.Engine.invokeActions(Native Method)
... 21 more
Caused by: java.lang.RuntimeException: 加载excel导入映射文件失败!
at com.justep.excel.ImportGenerator.loadMapping(ImportGenerator.java:83)
at com.justep.excel.ImportGenerator.init(ImportGenerator.java:59)
at com.justep.excel.ImportGenerator.generate(ImportGenerator.java:109)
at Excel.importExcel(Excel.java:63)
... 26 more
Caused by: org.dom4j.DocumentException: Error on line 2 of document file:///D:/X5.2.5/apache-tomcat/temp/243bb222-3780-4676-b674-fe6b7940171d.tmp : The processing instruction target matching "[xX][mM][lL]" is not allowed. Nested exception: The processing instruction target matching "[xX][mM][lL]" is not allowed.
at org.dom4j.io.SAXReader.read(SAXReader.java:482)
at org.dom4j.io.SAXReader.read(SAXReader.java:321)
at com.justep.excel.ImportGenerator.loadMapping(ImportGenerator.java:81)
... 29 more

url:
param:
at (http://127.0.0.1:8080/x5/$v963ee099e8744c3b98993394ee4ab68d/UI/system/components/excel/excel.js?language=zh_CN:1)


96

主题

399

帖子

1335

积分

金牌会员

Rank: 6Rank: 6

积分
1335
QQ
发表于 2013-10-30 15:52:37 | 显示全部楼层
<mapping>
        <default-config>
                <sheet all="false" start="1" end="1" />
                <row all="false" start="2" end="702" />
        </default-config>
        <concept name="OA_AS_Card">
                <!--<primary-key>注释
                        <key-value cell-number="1" check="true" />
                </primary-key>-->
                <relation name="fCode" cell-number="14" />
                <relation name="fSpecType" cell-number="15" ></relation>
                <relation name="fExtendDate1" cell-number="16" value-type="datetime" date-pattern="yyyy-MM-dd hh:mm:ss">
                </relation>
                <relation name="fOriginValue" cell-number="20" value-type="decimal"></relation>
                <relation name="fUsedName" cell-number="21" ></relation>
                <relation name="fDutyPsnName" cell-number="31" ></relation>
                <relation name="fDutyDeptName" cell-number="32"></relation>
                <relation name="fExtendStr3" cell-number="34"></relation>
                <relation name="fStatusName" cell-number="38"></relation>
                <relation name="fName" cell-number="41"></relation>
                <relation name="fRemark" cell-number="42"></relation>
                <relation name="fKind" cell-number="43"></relation>
        </concept>
</mapping>
映射文件没有列的相关信息

点评

牛  发表于 2013-10-30 18:33
回复 支持 反对

使用道具 举报

16

主题

35

帖子

93

积分

初级会员

Rank: 2

积分
93
QQ
 楼主| 发表于 2013-10-30 16:03:15 | 显示全部楼层
问题解决了。。。是关系大小写错误。。
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|X3技术论坛|Justep Inc.    

GMT+8, 2024-5-16 02:32 , Processed in 0.113761 second(s), 29 queries .

Powered by Discuz! X3.4

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表