caoyang0299 2015-05-18 05:04:31
有个问题
StringBuilder str = new StringBuilder();
str.Append(" select wipid,to_date(substr(txntimestamp, 0, 8) ||substr(txntimestamp, 10, 6), 'yyyy-mm-dd hh24:mi:ss') txntimestamp,userid_out ,");
str.Append(" to_date(substr(trackintime, 0, 8) ||substr(trackintime, 10, 6), 'yyyy-mm-dd hh24:mi:ss') trackintime,userid_in,productid,process,subplan,step,lastlocation,lotquantity,detaileddescription,ResonCode from v_eqplotcomment2_wip");
str.Append(" where 1=1 " + strEqpName + " and txntimestamp >='" + strStartTime + "' and txntimestamp <='" + strEndTime + "' ");
前台的一段代码。
问题是,前台web页能查出来结果,我在plsql里执行select * from jsmc.v_eqplotcomment2_wip where txntimestamp='20150517 090016000' 好长时间都不出结果。
plsql里比前台还慢。是什么原因,v_eqplotcomment2是个视图
...全文
101 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
jdsnhan 2015-05-19
  • 打赏
  • 举报
回复
1、你确认前台拼接出来的sql和你PLSQL执行的完全一样吗 2、查看plsql里面执行计划
caoyang0299 2015-05-19
  • 打赏
  • 举报
回复
哪位帮忙分析分析,是啥原因!

17,377

社区成员

发帖
与我相关
我的任务
社区描述
Oracle 基础和管理
社区管理员
  • 基础和管理社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧