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

QQ登录

只需一步,快速开始

楼主: lbx888

[结贴] 查询报错

[复制链接]

649

主题

2068

帖子

3741

积分

论坛元老

Rank: 8Rank: 8

积分
3741
QQ
 楼主| 发表于 2013-11-13 11:58:10 | 显示全部楼层
自己开发的功能
IMOM智能制造管理大师
官网:http://www.i-mom.cn
Tel:15905043811

649

主题

2068

帖子

3741

积分

论坛元老

Rank: 8Rank: 8

积分
3741
QQ
 楼主| 发表于 2013-11-13 11:59:05 | 显示全部楼层
执行ksql:SELECT OA_COMPACTEXAPP.*,b.fName as fCompactKindName,c.fName as fbizorginName,d.sName as fpersonsName,e.sName as fDeptName,f.sName as fMakePersonName,g.sName as fMakeDeptName,h.sName as fCreatePosName,j.fName as fdutyName  FROM OA_COMPACTEXAPP OA_COMPACTEXAPP  optional  join OA_Pub_BaseCode b on OA_COMPACTEXAPP.FCOMPKIND = b.fCode AND b.fScope = '公司合同类型' optional  join OA_Pub_BaseCode c on OA_COMPACTEXAPP.FBIZORIGN = c.fCode AND c.fScope = '单据所属公司' optional  join V_SA_OPOrg d on OA_COMPACTEXAPP.FCREATEURL = d.sFID AND d.sOrgKindID = 'psm' optional  join V_SA_OPOrg e on OA_COMPACTEXAPP.FCREATEDEPTID = e AND e.sOrgKindID = 'dpt' optional  join V_SA_OPOrg f on OA_COMPACTEXAPP.FCREATEPERID = f.sPersonID AND f.sOrgKindID = 'psm' optional  join V_SA_OPOrg g on OA_COMPACTEXAPP.FCPMakeDept = g AND g.sOrgKindID = 'dpt' optional  join V_SA_OPOrg h on OA_COMPACTEXAPP.FCREATEPOSID = h AND h.sOrgKindID = 'pos' optional  join OA_Pub_BaseCode j on OA_COMPACTEXAPP.fduty = j.fCode WHERE ((fBizState IN ('bsEditing','bsExecuting','bsFinished')) AND ((FCREATEPERID = '2E245EC4F99A423E9523D0D0F654630C') OR (OA_COMPACTEXAPP IN (SELECT EXECUTE_CONCEPT.fMasterID AS EXECUTE_CONCEPT_fMasterID FROM OA_COMPACTEXAPPExecute EXECUTE_CONCEPT WHERE EXECUTE_CONCEPT.fCreatePsnID = '2E245EC4F99A423E9523D0D0F654630C') )) AND ((((((((UPPER(FCREATEPERID) LIKE '%信息部%') OR (UPPER(FPRONAME) LIKE '%信息部%')) OR (UPPER(FCOMPACT) LIKE '%信息部%')) OR (UPPER(FCOMPKIND) LIKE '%信息部%')) OR (UPPER(FCOMPSUMR) LIKE '%信息部%')) OR (UPPER(FRealCompact) LIKE '%信息部%')) OR (UPPER(fBizStateName) LIKE '%信息部%')) OR (UPPER(fDeptName) LIKE '%信息部%'))) ORDER BY FCREATETIME DESC LIMIT 0, 100时出错!

这个是 平台自带控件 standardProcessQueryBar(标准流程查询工具栏)  并错出来KSQL语句
IMOM智能制造管理大师
官网:http://www.i-mom.cn
Tel:15905043811

91

主题

13万

帖子

3万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
36067
发表于 2013-11-13 13:55:28 | 显示全部楼层
这个是OA的appCommon中的,不是平台标准的,不是平台提供的组件,自己找一下看看组件中的实现
远程的联系方法QQ1392416607,添加好友时,需在备注里注明其论坛名字及ID,公司等信息
发远程时同时也发一下帖子地址,方便了解要解决的问题  WeX5教程  WeX5下载



如按照该方法解决,请及时跟帖,便于版主结贴

649

主题

2068

帖子

3741

积分

论坛元老

Rank: 8Rank: 8

积分
3741
QQ
 楼主| 发表于 2013-11-13 14:01:49 | 显示全部楼层
那要用哪个组件
IMOM智能制造管理大师
官网:http://www.i-mom.cn
Tel:15905043811

649

主题

2068

帖子

3741

积分

论坛元老

Rank: 8Rank: 8

积分
3741
QQ
 楼主| 发表于 2013-11-13 14:02:39 | 显示全部楼层
哥们
IMOM智能制造管理大师
官网:http://www.i-mom.cn
Tel:15905043811

91

主题

13万

帖子

3万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
36067
发表于 2013-11-13 14:19:08 | 显示全部楼层
自己放相关的XXXFilter组件进行过滤查询
远程的联系方法QQ1392416607,添加好友时,需在备注里注明其论坛名字及ID,公司等信息
发远程时同时也发一下帖子地址,方便了解要解决的问题  WeX5教程  WeX5下载



如按照该方法解决,请及时跟帖,便于版主结贴

649

主题

2068

帖子

3741

积分

论坛元老

Rank: 8Rank: 8

积分
3741
QQ
 楼主| 发表于 2013-11-14 08:49:49 | 显示全部楼层
用标准流程查询工具栏





设置进行模块过滤的字段

e.sName as fDeptName,f.sName as fMakePersonName,g.sName as fMakeDeptName 这些都是关联其他表 出来的字段
查询action 动作 ,KSQL语句:select OA_COMPACTEXAPP.*,b.fName as fCompactKindName,c.fName as fbizorginName,d.sName as fpersonsName,e.sName as fDeptName,f.sName as fMakePersonName,g.sName as fMakeDeptName,h.sName as fCreatePosName,j.fName as fdutyName
    from OA_COMPACTEXAPP OA_COMPACTEXAPP
     optional  join OA_Pub_BaseCode b on OA_COMPACTEXAPP.FCOMPKIND = b.fCode AND b.fScope = '公司合同类型'
     optional  join OA_Pub_BaseCode c on OA_COMPACTEXAPP.FBIZORIGN = c.fCode AND c.fScope = '单据所属公司'
     optional  join V_SA_OPOrg d on OA_COMPACTEXAPP.FCREATEURL = d.sFID AND d.sOrgKindID = 'psm'
     optional  join V_SA_OPOrg e on OA_COMPACTEXAPP.FCREATEDEPTID = e AND e.sOrgKindID = 'dpt'
     optional  join V_SA_OPOrg f on OA_COMPACTEXAPP.FCREATEPERID = f.sPersonID AND f.sOrgKindID = 'psm'
     optional  join V_SA_OPOrg g on OA_COMPACTEXAPP.FCPMakeDept = g AND g.sOrgKindID = 'dpt'
     optional  join V_SA_OPOrg h on OA_COMPACTEXAPP.FCREATEPOSID = h AND h.sOrgKindID = 'pos'
     optional  join OA_Pub_BaseCode j on OA_COMPACTEXAPP.fduty = j.fCode
QQ截图20131114084620.jpg
QQ图片20131114084516.jpg
IMOM智能制造管理大师
官网:http://www.i-mom.cn
Tel:15905043811

649

主题

2068

帖子

3741

积分

论坛元老

Rank: 8Rank: 8

积分
3741
QQ
 楼主| 发表于 2013-11-14 08:53:35 | 显示全部楼层
模糊过滤报错如下::



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: com.justep.model.exception.ModelException: 执行ksql:SELECT OA_COMPACTEXAPP.*,b.fName as fCompactKindName,c.fName as fbizorginName,d.sName as fpersonsName,e.sName as fDeptName,f.sName as fMakePersonName,g.sName as fMakeDeptName,h.sName as fCreatePosName,j.fName as fdutyName  FROM OA_COMPACTEXAPP OA_COMPACTEXAPP  optional  join OA_Pub_BaseCode b on OA_COMPACTEXAPP.FCOMPKIND = b.fCode AND b.fScope = '公司合同类型' optional  join OA_Pub_BaseCode c on OA_COMPACTEXAPP.FBIZORIGN = c.fCode AND c.fScope = '单据所属公司' optional  join V_SA_OPOrg d on OA_COMPACTEXAPP.FCREATEURL = d.sFID AND d.sOrgKindID = 'psm' optional  join V_SA_OPOrg e on OA_COMPACTEXAPP.FCREATEDEPTID = e AND e.sOrgKindID = 'dpt' optional  join V_SA_OPOrg f on OA_COMPACTEXAPP.FCREATEPERID = f.sPersonID AND f.sOrgKindID = 'psm' optional  join V_SA_OPOrg g on OA_COMPACTEXAPP.FCPMakeDept = g AND g.sOrgKindID = 'dpt' optional  join V_SA_OPOrg h on OA_COMPACTEXAPP.FCREATEPOSID = h AND h.sOrgKindID = 'pos' optional  join OA_Pub_BaseCode j on OA_COMPACTEXAPP.fduty = j.fCode WHERE ((fBizState IN ('bsEditing','bsExecuting','bsFinished')) AND ((FCREATEPERID = '2E245EC4F99A423E9523D0D0F654630C') OR (OA_COMPACTEXAPP IN (SELECT EXECUTE_CONCEPT.fMasterID AS EXECUTE_CONCEPT_fMasterID FROM OA_COMPACTEXAPPExecute EXECUTE_CONCEPT WHERE EXECUTE_CONCEPT.fCreatePsnID = '2E245EC4F99A423E9523D0D0F654630C') )) AND ((((((((UPPER(FCREATEPERID) LIKE '%DD%') OR (UPPER(FPRONAME) LIKE '%DD%')) OR (UPPER(FCOMPACT) LIKE '%DD%')) OR (UPPER(FCOMPKIND) LIKE '%DD%')) OR (UPPER(FCOMPSUMR) LIKE '%DD%')) OR (UPPER(FRealCompact) LIKE '%DD%')) OR (UPPER(fBizStateName) LIKE '%DD%')) OR (UPPER(fDeptName) LIKE '%DD%'))) ORDER BY FCREATETIME DESC LIMIT 0, 100时出错!
at com.justep.system.data.impl.TableUtilsImplement.ksqlSelect(Unknown Source)
at com.justep.system.data.impl.TableUtilsImplement.ksqlSelect(Unknown Source)
at com.justep.system.data.impl.TableUtilsImplement.ksqlSelect(Unknown Source)
at com.justep.system.data.BizData.query(Unknown Source)
at BizProcedure.query(BizProcedure.java:12)
... 26 more
Caused by: java.sql.SQLException: 列名 'fDeptName' 无效。
at net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:365)
at net.sourceforge.jtds.jdbc.TdsCore.tdsErrorToken(TdsCore.java:2781)
at net.sourceforge.jtds.jdbc.TdsCore.nextToken(TdsCore.java:2224)
at net.sourceforge.jtds.jdbc.TdsCore.getMoreResults(TdsCore.java:628)
at net.sourceforge.jtds.jdbc.JtdsStatement.executeSQLQuery(JtdsStatement.java:418)
at net.sourceforge.jtds.jdbc.JtdsPreparedStatement.executeQuery(JtdsPreparedStatement.java:693)
at org.apache.tomcat.dbcp.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96)
at org.apache.tomcat.dbcp.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96)
at com.justep.system.ksql.KSQLUtils.execSqlSelect(Unknown Source)
... 31 more
QQ图片20131114085237.jpg
IMOM智能制造管理大师
官网:http://www.i-mom.cn
Tel:15905043811

649

主题

2068

帖子

3741

积分

论坛元老

Rank: 8Rank: 8

积分
3741
QQ
 楼主| 发表于 2013-11-14 08:56:34 | 显示全部楼层
报错
QQ截图20131114085532.jpg
IMOM智能制造管理大师
官网:http://www.i-mom.cn
Tel:15905043811

24

主题

400

帖子

1749

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
1749
发表于 2013-11-14 14:20:18 | 显示全部楼层
你好,你的平台版本是什么,Appcommon是从哪里获取的?
我们这边根据你的环境,看看能不能重现问题
高级模式
B Color Image Link Quote Code Smilies |上传

本版积分规则

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

GMT+8, 2024-11-23 05:03 , Processed in 0.121025 second(s), 23 queries .

Powered by Discuz! X3.4

© 2001-2013 Comsenz Inc.

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