123
返回列表 发新帖
楼主: liangxinf

[原创] 打开会计期慢的问题

[复制链接]
论坛徽章:
10
授权会员
日期:2007-07-18 11:34:32ITPUB新首页上线纪念徽章
日期:2007-10-20 08:38:44生肖徽章2007版:鸡
日期:2008-12-02 12:45:45生肖徽章2007版:龙
日期:2008-12-07 18:27:322009新春纪念徽章
日期:2009-01-04 14:52:28生肖徽章2007版:猪
日期:2009-02-18 12:56:472009日食纪念
日期:2009-07-22 09:30:00
21#
发表于 2009-10-23 14:04 | 只看该作者
从你的trace情况来看, 插入28w笔, cost是OK的.
我发现 有如下的error:

error during execute of EXPLAIN PLAN statement
ORA-00904: "B"."SET_OF_BOOKS_ID": invalid identifier

sob id = 2002 , 有什么问题嘛?

在post的时候,你们做过什么客制没有?

使用道具 举报

回复
论坛徽章:
14
数据库板块每日发贴之星
日期:2005-05-15 01:01:24生肖徽章2007版:鸡
日期:2009-11-17 15:01:30生肖徽章2007版:马
日期:2009-10-22 08:53:062009新春纪念徽章
日期:2009-01-04 14:52:28数据库板块每日发贴之星
日期:2008-12-28 01:01:02ERP板块每日发贴之星
日期:2008-11-29 01:01:04数据库板块每日发贴之星
日期:2008-04-25 01:01:54生肖徽章2007版:鸡
日期:2008-01-02 17:35:53ITPUB新首页上线纪念徽章
日期:2007-10-20 08:38:44会员2007贡献徽章
日期:2007-09-26 18:42:10
22#
发表于 2009-10-23 14:12 | 只看该作者
应该是有做客户化,oracle不会这么写的!

使用道具 举报

回复
论坛徽章:
14
数据库板块每日发贴之星
日期:2005-05-15 01:01:24生肖徽章2007版:鸡
日期:2009-11-17 15:01:30生肖徽章2007版:马
日期:2009-10-22 08:53:062009新春纪念徽章
日期:2009-01-04 14:52:28数据库板块每日发贴之星
日期:2008-12-28 01:01:02ERP板块每日发贴之星
日期:2008-11-29 01:01:04数据库板块每日发贴之星
日期:2008-04-25 01:01:54生肖徽章2007版:鸡
日期:2008-01-02 17:35:53ITPUB新首页上线纪念徽章
日期:2007-10-20 08:38:44会员2007贡献徽章
日期:2007-09-26 18:42:10
23#
发表于 2009-10-23 14:27 | 只看该作者
刚查了,不是客户化!
ORA-00904: "B"."SET_OF_BOOKS_ID": invalid identifier 好像蛮普遍的!

使用道具 举报

回复
论坛徽章:
1
授权会员
日期:2005-10-30 17:05:33
24#
 楼主| 发表于 2009-10-23 15:53 | 只看该作者
ORA-00904: "B"."SET_OF_BOOKS_ID": invalid identifier错误应该是我在本机进行分析时出的错,我这里安装的是R12,所以没有set_of_books_id字段的。

这个应该没有关系。

使用道具 举报

回复
论坛徽章:
1
授权会员
日期:2005-10-30 17:05:33
25#
 楼主| 发表于 2009-10-23 15:55 | 只看该作者
原帖由 goodhawk 于 2009-10-23 14:04 发表
从你的trace情况来看, 插入28w笔, cost是OK的.
我发现 有如下的error:

error during execute of EXPLAIN PLAN statement
ORA-00904: "B"."SET_OF_BOOKS_ID": invalid identifier

sob id = 2002 , 有什么问题嘛?

在post的时候,你们做过什么客制没有?



你意思插入28条记录到表中使用30-60分钟的时间是正常的?

使用道具 举报

回复
论坛徽章:
14
数据库板块每日发贴之星
日期:2005-05-15 01:01:24生肖徽章2007版:鸡
日期:2009-11-17 15:01:30生肖徽章2007版:马
日期:2009-10-22 08:53:062009新春纪念徽章
日期:2009-01-04 14:52:28数据库板块每日发贴之星
日期:2008-12-28 01:01:02ERP板块每日发贴之星
日期:2008-11-29 01:01:04数据库板块每日发贴之星
日期:2008-04-25 01:01:54生肖徽章2007版:鸡
日期:2008-01-02 17:35:53ITPUB新首页上线纪念徽章
日期:2007-10-20 08:38:44会员2007贡献徽章
日期:2007-09-26 18:42:10
26#
发表于 2009-10-23 16:54 | 只看该作者
insert into gl_open_interim       (code_combination_id, period_name,      
  set_of_books_id,     currency_code,       period_year,         period_num,  
       period_type,       actual_flag, translated_flag,        period_net_dr,
        period_net_cr,    period_net_dr_beq,     period_net_cr_beq,      
  quarter_to_date_dr,  quarter_to_date_cr,       project_to_date_dr,  
  project_to_date_cr,       begin_balance_dr,    begin_balance_cr,      
  begin_balance_dr_beq,    begin_balance_cr_beq,       template_id) select
  b.code_combination_id,         decode(b.set_of_books_id ,              2002,
   '2009-09-23', 'ERROR'),       b.set_of_books_id,       b.currency_code,   
       decode(b.set_of_books_id,              2002, 2009 ,-1),         
  decode(b.set_of_books_id,               2002, 266 ,-1),         
  decode(b.set_of_books_id,              2002, '43' ,'ERROR'),      
  b.actual_flag,decode(b.set_of_books_id,2002,decode(b.currency_code,'RMB',
  NULL,'STAT',NULL,'R'),0),       0 , 0,0,0,         decode(b.set_of_books_id
  ,              2002, nvl(b.quarter_to_date_dr,0) + nvl(b.period_net_dr,0) ,
  -1),         decode(b.set_of_books_id,              2002,
  nvl(b.quarter_to_date_cr,0) + nvl(b.period_net_cr,0) ,-1),
  nvl(b.project_to_date_dr,0) + nvl(b.period_net_dr,0),
  nvl(b.project_to_date_cr,0) + nvl(b.period_net_cr,0),
  nvl(b.begin_balance_dr,0) + nvl(b.period_net_dr,0),  nvl(b.begin_balance_cr,
  0) + nvl(b.period_net_cr,0), decode(b.set_of_books_id,2002,
  decode(b.currency_code,'STAT',0,nvl(b.begin_balance_dr_beq,0)
  +nvl(b.period_net_dr_beq,0)),0),decode(b.set_of_books_id,2002,
  decode(b.currency_code,'STAT',0,nvl(b.begin_balance_cr_beq,0)
  +nvl(b.period_net_cr_beq,0)),0),      b.template_id from   gl_balances b,   
       gl_sets_of_books sob  where  b.actual_flag     = 'A'  and  (
  b.currency_code in (sob.currency_code,'STAT')      or translated_flag='R' )
   and    b.set_of_books_id = sob.set_of_books_id  and    b.period_name     =
  sob.latest_opened_period_name  and    (sob.set_of_books_id = 2002 )



call     count       cpu    elapsed       disk      query    current        rows
------- ------  -------- ---------- ---------- ---------- ----------  ----------
Parse        1      0.02       0.01          0          0          0           0
Execute      1     15.42     123.94      88065     113785    1030900      284349
Fetch        0      0.00       0.00          0          0          0           0
------- ------  -------- ---------- ---------- ---------- ----------  ----------
total        2     15.44     123.95      88065     113785    1030900      284349
他指的应该使这个
284349条记录,耗时123秒,不多

使用道具 举报

回复
论坛徽章:
14
数据库板块每日发贴之星
日期:2005-05-15 01:01:24生肖徽章2007版:鸡
日期:2009-11-17 15:01:30生肖徽章2007版:马
日期:2009-10-22 08:53:062009新春纪念徽章
日期:2009-01-04 14:52:28数据库板块每日发贴之星
日期:2008-12-28 01:01:02ERP板块每日发贴之星
日期:2008-11-29 01:01:04数据库板块每日发贴之星
日期:2008-04-25 01:01:54生肖徽章2007版:鸡
日期:2008-01-02 17:35:53ITPUB新首页上线纪念徽章
日期:2007-10-20 08:38:44会员2007贡献徽章
日期:2007-09-26 18:42:10
27#
发表于 2009-10-23 16:54 | 只看该作者
这个问题我觉得你还是好好等sr的回复吧,他是个派生的程序,就算我们发现了问题也无法处理

使用道具 举报

回复
论坛徽章:
48
ITPUB元老
日期:2008-03-18 08:54:04马上有钱
日期:2014-03-13 14:01:55马上有车
日期:2014-02-18 16:41:112014年新春福章
日期:2014-02-18 16:41:11林肯
日期:2013-08-29 13:42:39红旗
日期:2013-08-02 17:22:082013年新春福章
日期:2013-02-25 14:51:24ITPUB 11周年纪念徽章
日期:2012-10-09 18:05:37ITPUB十周年纪念徽章
日期:2011-11-01 16:20:282010年世界杯参赛球队:法国
日期:2009-12-21 05:25:54
28#
发表于 2009-10-24 21:49 | 只看该作者
UP

使用道具 举报

回复
论坛徽章:
10
授权会员
日期:2007-07-18 11:34:32ITPUB新首页上线纪念徽章
日期:2007-10-20 08:38:44生肖徽章2007版:鸡
日期:2008-12-02 12:45:45生肖徽章2007版:龙
日期:2008-12-07 18:27:322009新春纪念徽章
日期:2009-01-04 14:52:28生肖徽章2007版:猪
日期:2009-02-18 12:56:472009日食纪念
日期:2009-07-22 09:30:00
29#
发表于 2009-10-25 21:14 | 只看该作者
原帖由 remen 于 2009-10-23 16:54 发表
insert into gl_open_interim       (code_combination_id, period_name,      
  set_of_books_id,     currency_code,       period_year,         period_num,  
       period_type,       actual_flag, translated_flag,        period_net_dr,
        period_net_cr,    period_net_dr_beq,     period_net_cr_beq,      
  quarter_to_date_dr,  quarter_to_date_cr,       project_to_date_dr,  
  project_to_date_cr,       begin_balance_dr,    begin_balance_cr,      
  begin_balance_dr_beq,    begin_balance_cr_beq,       template_id) select
  b.code_combination_id,         decode(b.set_of_books_id ,              2002,
   '2009-09-23', 'ERROR'),       b.set_of_books_id,       b.currency_code,   
       decode(b.set_of_books_id,              2002, 2009 ,-1),         
  decode(b.set_of_books_id,               2002, 266 ,-1),         
  decode(b.set_of_books_id,              2002, '43' ,'ERROR'),      
  b.actual_flag,decode(b.set_of_books_id,2002,decode(b.currency_code,'RMB',
  NULL,'STAT',NULL,'R'),0),       0 , 0,0,0,         decode(b.set_of_books_id
  ,              2002, nvl(b.quarter_to_date_dr,0) + nvl(b.period_net_dr,0) ,
  -1),         decode(b.set_of_books_id,              2002,
  nvl(b.quarter_to_date_cr,0) + nvl(b.period_net_cr,0) ,-1),
  nvl(b.project_to_date_dr,0) + nvl(b.period_net_dr,0),
  nvl(b.project_to_date_cr,0) + nvl(b.period_net_cr,0),
  nvl(b.begin_balance_dr,0) + nvl(b.period_net_dr,0),  nvl(b.begin_balance_cr,
  0) + nvl(b.period_net_cr,0), decode(b.set_of_books_id,2002,
  decode(b.currency_code,'STAT',0,nvl(b.begin_balance_dr_beq,0)
  +nvl(b.period_net_dr_beq,0)),0),decode(b.set_of_books_id,2002,
  decode(b.currency_code,'STAT',0,nvl(b.begin_balance_cr_beq,0)
  +nvl(b.period_net_cr_beq,0)),0),      b.template_id from   gl_balances b,   
       gl_sets_of_books sob  where  b.actual_flag     = 'A'  and  (
  b.currency_code in (sob.currency_code,'STAT')      or translated_flag='R' )
   and    b.set_of_books_id = sob.set_of_books_id  and    b.period_name     =
  sob.latest_opened_period_name  and    (sob.set_of_books_id = 2002 )



call     count       cpu    elapsed       disk      query    current        rows
------- ------  -------- ---------- ---------- ---------- ----------  ----------
Parse        1      0.02       0.01          0          0          0           0
Execute      1     15.42     123.94      88065     113785    1030900      284349
Fetch        0      0.00       0.00          0          0          0           0
------- ------  -------- ---------- ---------- ---------- ----------  ----------
total        2     15.44     123.95      88065     113785    1030900      284349
他指的应该使这个
284349条记录,耗时123秒,不多


对头,是那个时点oracle post 了 28万 笔到 gl_balance , 我认为还行.

使用道具 举报

回复

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

本版积分规则 发表回复

TOP技术积分榜 社区积分榜 徽章 团队 统计 知识索引树 积分竞拍 文本模式 帮助
  ITPUB首页 | ITPUB论坛 | 数据库技术 | 企业信息化 | 开发技术 | 微软技术 | 软件工程与项目管理 | IBM技术园地 | 行业纵向讨论 | IT招聘 | IT文档
  ChinaUnix | ChinaUnix博客 | ChinaUnix论坛
CopyRight 1999-2011 itpub.net All Right Reserved. 北京盛拓优讯信息技术有限公司版权所有 联系我们 未成年人举报专区 
京ICP备16024965号-8  北京市公安局海淀分局网监中心备案编号:11010802021510 广播电视节目制作经营许可证:编号(京)字第1149号
  
快速回复 返回顶部 返回列表