Chinaunix首页 | 论坛 | 博客
  • 博客访问: 2623078
  • 博文数量: 323
  • 博客积分: 10211
  • 博客等级: 上将
  • 技术积分: 4934
  • 用 户 组: 普通用户
  • 注册时间: 2006-08-27 14:56
文章分类

全部博文(323)

文章存档

2012年(5)

2011年(3)

2010年(6)

2009年(140)

2008年(169)

分类: Oracle

2009-07-29 15:04:25

周一收到事业部同事的邮件,邮件提到装入计划ODS工作进程请求出现警告,问这对ASCP的运行结果有没有影响?具体的请求日志如下:
 
+---------------------------------------------------------------------------+
高级供应链计划管理系统: Version : 11.5.0 - Development
Copyright (c) 1979, 1999, Oracle Corporation. All rights reserved.
MSCPDCW module: 装入计划 ODS 工作进程
+---------------------------------------------------------------------------+
当前的系统时间为 27-07-2009 01:08:32
+---------------------------------------------------------------------------+
**Starts**27-07-2009 01:08:32
**Ends**27-07-2009 01:13:11
装入计划 ODS 流程成功。
+---------------------------------------------------------------------------+
FND_FILE 中日志消息开始
+---------------------------------------------------------------------------+
“清除批量”设置为:25000。
dp enabled orgs present
已启动过程 LOAD_SUPPLY。
load_supply
 Index SUPPLIES_NX_CVN created.
 Index SUPPLIES_NX1_CVN created.
 Index SUPPLIES_NX2_CVN created.
Index creation on Temp Supplies table successful.
Total MSC_JOB_OP_RES_INSTANCES = 0
经过 .5 分钟。
已启动过程 LOAD_OPERATION_NETWORKS。
   已启动过程 DELETE_MSC_TABLE:MSC_OPERATION_NETWORKS。
   经过 0 分钟。
经过 0 分钟。
已启动过程 LOAD_PROCESS_EFFECTIVITY。
   已启动过程 DELETE_MSC_TABLE:MSC_PROCESS_EFFECTIVITY。
   经过 .1 分钟。
经过 .2 分钟。
已启动过程 LOAD_OPERATION_RESOURCES。
The sql statement is  INSERT INTO OPERATION_RESOURCES_CVN ( PLAN_ID,    ROUTING_SEQUENCE_ID,    OPERATION_SEQUENCE_ID,    RESOURCE_SEQ_NUM,    RESOURCE_ID,    ALTERNATE_NUMBER,    PRINCIPAL_FLAG,    BASIS_TYPE,    RESOURCE_USAGE,    MAX_RESOURCE_UNITS,    RESOURCE_UNITS,    UOM_CODE,    RESOURCE_TYPE,    SR_INSTANCE_ID,    ORGANIZATION_ID,    SETUP_ID,    MINIMUM_CAPACITY,    MAXIMUM_CAPACITY,    orig_resource_seq_num,    BREAKABLE_ACTIVITY_FLAG,    REFRESH_NUMBER,    LAST_UPDATE_DATE,    LAST_UPDATED_BY,    CREATION_DATE,    CREATED_BY) SELECT -1,msor.ROUTING_SEQUENCE_ID,msor.OPERATION_SEQUENCE_ID,msor.RESOURCE_SEQ_NUM,msor.RESOURCE_ID,msor.ALTERNATE_NUMBER,nvl(msor.PRINCIPAL_FLAG,1) PRINCIPAL_FLAG,msor.BASIS_TYPE,msor.RESOURCE_USAGE,msor.MAX_RESOURCE_UNITS,msor.RESOURCE_UNITS,msor.UOM_CODE,msor.RESOURCE_TYPE,msor.SR_INSTANCE_ID,msor.ORGANIZATION_ID,msor.SETUP_ID,msor.MINIMUM_CAPACITY,msor.MAXIMUM_CAPACITY ,msor.orig_resource_seq_num,msor.BREAKABLE_ACTIVITY_FLAG, :v_last_collection_id, :v_current_date, :v_current_user, :v_current_date, :v_current_user FROM MSC_ST_OPERATION_RESOURCES msor WHERE msor.SR_INSTANCE_ID=1AND msor.DELETED_FLAG=2
========================================
发生错误,PROCEDURE=LOAD_OPERATION_RESOURCES, TABLE=MSC_OPERATION_RESOURCES
ORA-00001: 违反唯一约束条件 (MSC.OPERATION_RESOURCES_U1_CVN)
bulk insert failed - operation resources
========================================
发生错误,PROCEDURE=LOAD_OPERATION_RESOURCES, TABLE=MSC_OPERATION_RESOURCES
COLUMN=ROUTING_SEQUENCE_ID, VALUE=349534
COLUMN=OPERATION_SEQUENCE_ID, VALUE=770264
COLUMN=RESOURCE_SEQ_NUM, VALUE=100
COLUMN=RESOURCE_ID, VALUE=992
ORA-00001: 违反唯一约束条件 (MSC.OPERATION_RESOURCES_U1_CVN)
========================================
发生错误,PROCEDURE=LOAD_OPERATION_RESOURCES, TABLE=MSC_OPERATION_RESOURCES
COLUMN=ROUTING_SEQUENCE_ID, VALUE=339436
COLUMN=OPERATION_SEQUENCE_ID, VALUE=758252
COLUMN=RESOURCE_SEQ_NUM, VALUE=100
COLUMN=RESOURCE_ID, VALUE=1020
ORA-00001: 违反唯一约束条件 (MSC.OPERATION_RESOURCES_U1_CVN)
========================================
发生错误,PROCEDURE=LOAD_OPERATION_RESOURCES, TABLE=MSC_OPERATION_RESOURCES
COLUMN=ROUTING_SEQUENCE_ID, VALUE=19948
COLUMN=OPERATION_SEQUENCE_ID, VALUE=88376
COLUMN=RESOURCE_SEQ_NUM, VALUE=100
COLUMN=RESOURCE_ID, VALUE=990
ORA-00001: 违反唯一约束条件 (MSC.OPERATION_RESOURCES_U1_CVN)
The sql statement is INSERT INTO OPERATION_RESOURCES_CVN SELECT * from MSC_OPERATION_RESOURCES WHERE sr_instance_id = 1 AND plan_id = -1  AND organization_id not  IN (103,107,104)
经过 .1 分钟。
已启动过程 LOAD_COMPONENT_SUBSTITUTE。
   已启动过程 DELETE_MSC_TABLE:MSC_COMPONENT_SUBSTITUTES。
   经过 .1 分钟。
经过 .1 分钟。
已启动过程 LOAD_OP_RESOURCE_SEQ。
========================================
发生错误,PROCEDURE=LOAD_OP_RESOURCE_SEQ, TABLE=MSC_OPERATION_RESOURCE_SEQS
ORA-00001: 违反唯一约束条件 (MSC.OPERATION_RESOURCE_SEQS_U1_CVN)
bulk insert failed - operation resource seqs
The sql statement is INSERT INTO OPERATION_RESOURCE_SEQS_CVN SELECT * from MSC_OPERATION_RESOURCE_SEQS WHERE sr_instance_id = 1 AND plan_id = -1  AND organization_id not  IN (103,107,104)
经过 .2 分钟。
已启动过程 LOAD_CATEGORY。
The sql statement is INSERT INTO ITEM_CATEGORIES_CVN SELECT * from MSC_ITEM_CATEGORIES WHERE sr_instance_id = 1 AND organization_id not  IN (103,107,104)
经过 .1 分钟。
已启动过程 LOAD_ITEM。
The sql statement is INSERT INTO SYSTEM_ITEMS_CVN SELECT * from MSC_SYSTEM_ITEMS WHERE sr_instance_id = 1 AND plan_id = -1  AND organization_id not  IN (103,107,104)
已启动过程 LOAD_SUPPLIER_CAPACITY。
   已启动过程 DELETE_MSC_TABLE:MSC_ITEM_SUPPLIERS。
   经过 .1 分钟。
   已启动过程 DELETE_MSC_TABLE:MSC_SUPPLIER_CAPACITIES。
   经过 0 分钟。
   已启动过程 DELETE_MSC_TABLE:MSC_SUPPLIER_FLEX_FENCES。
   经过 0 分钟。
经过 .4 分钟。
已启动过程 LOAD_DEMAND。
经过 .1 分钟。
已启动过程 LOAD_ITEM_FORECASTS。
经过 0 分钟。
已启动过程 LOAD_WIP_DEMAND。
经过 .1 分钟。
已启动过程 LOAD_RES_REQ。
Total resource charges  = 0
经过 .1 分钟。
已启动过程 LOAD_SALES_ORDER。
 Calling Linking of Sales Order for 11i source ...
MSC_DL_TASK_START_PARTIAL (PROCEDURE=LINK_SUPP_SO_DEMAND_11I2)
==========================================================
Starting LINK_SUPP_SO_DEMAND_11I2 ......
Supply table is: SUPPLIES_CVN
==========================================================
经过 .3 分钟。
已启动过程 LOAD_BIS_TARGETS。
   已启动过程 DELETE_MSC_TABLE:MSC_BIS_TARGETS。
   经过 0 分钟。
经过 0 分钟。
已启动过程 LOAD_PLANNERS。
   已启动过程 DELETE_MSC_TABLE:MSC_PLANNERS。
   经过 0 分钟。
经过 .1 分钟。
已启动过程 LOAD_DEMAND_CLASS。
   已启动过程 DELETE_MSC_TABLE:MSC_DEMAND_CLASSES。
   经过 0 分钟。
经过 0 分钟。
已启动过程 LOAD_RESOURCE。
经过 0 分钟。
已启动过程 LOAD_SUB_INVENTORY。
   已启动过程 DELETE_MSC_TABLE:MSC_SUB_INVENTORIES。
   经过 0 分钟。
经过 .1 分钟。
已启动过程 LOAD_HARD_RESERVATION。
   已启动过程 DELETE_MSC_TABLE:MSC_RESERVATIONS。
   经过 .1 分钟。
经过 .1 分钟。
已启动过程 LOAD_BIS_TARGET_LEVELS。
   已启动过程 DELETE_MSC_TABLE:MSC_BIS_TARGET_LEVELS。
   经过 .1 分钟。
经过 .1 分钟。
已启动过程 LOAD_BIS_BUSINESS_PLANS。
   已启动过程 DELETE_MSC_TABLE:MSC_BIS_BUSINESS_PLANS。
   经过 0 分钟。
经过 0 分钟。
已启动过程 LOAD_BIS_PERIODS。
   已启动过程 DELETE_MSC_TABLE:MSC_BIS_PERIODS。
   经过 0 分钟。
经过 .1 分钟。
经过 0 分钟。
已启动过程 LOAD_TRIP。
   已启动过程 DELETE_MSC_TABLE:MSC_TRIPS。
   经过 0 分钟。
   已启动过程 DELETE_MSC_TABLE:MSC_TRIP_STOPS。
   经过 0 分钟。
经过 0 分钟。
已启动过程 LOAD_ABC_CLASSES。
   已启动过程 DELETE_MSC_TABLE:MSC_ABC_CLASSES。
   经过 0 分钟。
经过 0 分钟。
已启动过程 LOAD_RES_INST_REQ。
Total wip res instance= 0
Total wip res instance= 0
经过 0 分钟。
已启动过程 LOAD_RESOURCE_SETUP。
   已启动过程 DELETE_MSC_TABLE:MSC_RESOURCE_SETUPS。
   经过 0 分钟。
Total resource setups = 0
经过 0 分钟。
已启动过程 LOAD_SETUP_TRANSITION。
   已启动过程 DELETE_MSC_TABLE:MSC_SETUP_TRANSITIONS。
   经过 0 分钟。
Total resource transition = 0
经过 0 分钟。
已启动过程 LOAD_STD_OP_RESOURCES。
   已启动过程 DELETE_MSC_TABLE:MSC_STD_OP_RESOURCES。
   经过 0 分钟。
Total std op resources = 0
经过 0 分钟。
装入计划 ODS 流程成功。
+---------------------------------------------------------------------------+
FND_FILE 中日志消息结束
+---------------------------------------------------------------------------+

+---------------------------------------------------------------------------+
正在执行请求完成选项...

未打印输出文件,因为:
已禁用此报表的打印选项。

已完成执行请求完成选项。
+---------------------------------------------------------------------------+
已完成并发请求
当前的系统时间为 27-07-2009 01:13:11
+---------------------------------------------------------------------------+

 
查了一下metalink发现Note 294078.1描述的问题跟我们的遇到的问题比较类似。利用oracle提供的脚本查询了一下,发现一些问题。脚本如下:
 
PROMPT ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID 
PROMPT OPERATION_SEQUENCE_ID = &OP_SEQ_ID
PROMPT RESOURCE_SEQ_NUM = &RES_SEQ_NUM 
PROMPT RESOURCE_ID = &RES_ID
 
SELECT
  SCHEDULE_SEQ_NUM SSN,
  BASIS_TYPE BT,
  UOM_CODE UC,
  PRINCIPAL_FLAG PF
FROM
  MRP_AP_OPERATION_RESOURCES_V
WHERE
  ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID  AND
  OPERATION_SEQUENCE_ID = &OP_SEQ_ID  AND
  --RESOURCE_ID = &RES_ID  --AND
  RESOURCE_SEQ_NUM = &RES_SEQ_NUM;
 
SELECT
  SCHEDULE_SEQ_NUM SSN,
  BASIS_TYPE BT,
  UOM_CODE UC,
  PRINCIPAL_FLAG PF
FROM
  MRP_AP_OPERATION_RESOURCES_V
WHERE
  --ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID  AND
  --OPERATION_SEQUENCE_ID = &OP_SEQ_ID  AND
  RESOURCE_ID = &RES_ID  AND
  RESOURCE_SEQ_NUM = &RES_SEQ_NUM;
 
SELECT
  SCHEDULE_SEQ_NUM SSN,
  BASIS_TYPE BT,
  UOM_CODE UC,
  PRINCIPAL_FLAG PF
FROM
  MRP_AP_OPERATION_RESOURCES_V
WHERE
  ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID  AND
  OPERATION_SEQUENCE_ID = &OP_SEQ_ID  AND
  RESOURCE_ID = &RES_ID; 
  --AND  RESOURCE_SEQ_NUM = &RES_SEQ_NUM
 
SELECT
  SCHEDULE_SEQ_NUM,
  NVL(ALTERNATE_NUMBER  ,
  0) ALT_NUM ,
  RESOURCE_SEQ_NUM
FROM
  MRP_AP_OPERATION_RESOURCES_V
WHERE
  ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID  AND
  OPERATION_SEQUENCE_ID = &OP_SEQ_ID  AND
  RESOURCE_ID = &RES_ID;
SELECT
  SCHEDULE_SEQ_NUM,
  RESOURCE_SEQ_NUM,
  SCHEDULE_FLAG
FROM
  BOM_OPERATION_RESOURCES
WHERE
  RESOURCE_ID = (&RES_ID/2)  AND
  OPERATION_SEQUENCE_ID = (&OP_SEQ_ID/2);

SELECT
  REPLACEMENT_GROUP_NUM,
  SCHEDULE_SEQ_NUM,
  SCHEDULE_FLAG,
  SUBSTITUTE_GROUP_NUM
FROM
  BOM_SUB_OPERATION_RESOURCES
WHERE
  RESOURCE_ID = (&RES_ID/2)  AND
  OPERATION_SEQUENCE_ID = (&OP_SEQ_ID/2);

 
脚本输出的结果如下:
 
Enter value for rout_seq_id: 349534
ROUTING_SEQUENCE_ID = 349534
Enter value for op_seq_id: 770264
OPERATION_SEQUENCE_ID = 770264
Enter value for res_seq_num: 100
RESOURCE_SEQ_NUM = 100
Enter value for res_id: 992
RESOURCE_ID = 992
Enter value for rout_seq_id: 349534
old   9: ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: ROUTING_SEQUENCE_ID = 349534 AND
Enter value for op_seq_id: 770264
old  10: OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: OPERATION_SEQUENCE_ID = 770264 AND
Enter value for res_id: 992
old  11: --RESOURCE_ID = &RES_ID --AND
new  11: --RESOURCE_ID = 992 --AND
Enter value for res_seq_num: 100
old  12: RESOURCE_SEQ_NUM = &RES_SEQ_NUM
new  12: RESOURCE_SEQ_NUM = 100
no rows selected
Enter value for rout_seq_id: 349534
old   9: --ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: --ROUTING_SEQUENCE_ID = 349534 AND
Enter value for op_seq_id: 770264
old  10: --OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: --OPERATION_SEQUENCE_ID = 770264 AND
Enter value for res_id: 992
old  11: RESOURCE_ID = &RES_ID AND
new  11: RESOURCE_ID = 992 AND
Enter value for res_seq_num: 100
old  12: RESOURCE_SEQ_NUM = &RES_SEQ_NUM
new  12: RESOURCE_SEQ_NUM = 100
no rows selected
Enter value for rout_seq_id: 349534
old   9: ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: ROUTING_SEQUENCE_ID = 349534 AND
Enter value for op_seq_id: 770264
old  10: OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: OPERATION_SEQUENCE_ID = 770264 AND
Enter value for res_id: 992
old  11: RESOURCE_ID = &RES_ID
new  11: RESOURCE_ID = 992
       SSN         BT UC          PF                                           
---------- ---------- --- ----------                                           
       100          1 Hr           2                                           
       100          1 Hr           2                                           
Enter value for rout_seq_id: 349534
old   9: ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: ROUTING_SEQUENCE_ID = 349534 AND
Enter value for op_seq_id: 770264
old  10: OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: OPERATION_SEQUENCE_ID = 770264 AND
Enter value for res_id: 992
old  11: RESOURCE_ID = &RES_ID
new  11: RESOURCE_ID = 992
SCHEDULE_SEQ_NUM    ALT_NUM RESOURCE_SEQ_NUM                                   
---------------- ---------- ----------------                                   
             100          0               40                                   
             100          0               60                                   
Enter value for res_id: 992
old   8: RESOURCE_ID = (&RES_ID/2) AND
new   8: RESOURCE_ID = (992/2) AND
Enter value for op_seq_id: 770264
old   9: OPERATION_SEQUENCE_ID = (&OP_SEQ_ID/2)
new   9: OPERATION_SEQUENCE_ID = (770264/2)
SCHEDULE_SEQ_NUM RESOURCE_SEQ_NUM SCHEDULE_FLAG                                
---------------- ---------------- -------------                                
             100               40             1                                
             100               60             1                                
Enter value for res_id: 992
old   9: RESOURCE_ID = (&RES_ID/2) AND
new   9: RESOURCE_ID = (992/2) AND
Enter value for op_seq_id: 770264
old  10: OPERATION_SEQUENCE_ID = (&OP_SEQ_ID/2)
new  10: OPERATION_SEQUENCE_ID = (770264/2)
no rows selected

SQL> @check.sql
Enter value for rout_seq_id: 19948
ROUTING_SEQUENCE_ID = 19948
Enter value for op_seq_id: 88376
OPERATION_SEQUENCE_ID = 88376
Enter value for res_seq_num: 100
RESOURCE_SEQ_NUM = 100
Enter value for res_id: 990
RESOURCE_ID = 990
Enter value for rout_seq_id: 19948
old   9: ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: ROUTING_SEQUENCE_ID = 19948 AND
Enter value for op_seq_id: 88376
old  10: OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: OPERATION_SEQUENCE_ID = 88376 AND
Enter value for res_id: 990
old  11: --RESOURCE_ID = &RES_ID --AND
new  11: --RESOURCE_ID = 990 --AND
Enter value for res_seq_num: 100
old  12: RESOURCE_SEQ_NUM = &RES_SEQ_NUM
new  12: RESOURCE_SEQ_NUM = 100
no rows selected
Enter value for rout_seq_id: 19948
old   9: --ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: --ROUTING_SEQUENCE_ID = 19948 AND
Enter value for op_seq_id: 88376
old  10: --OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: --OPERATION_SEQUENCE_ID = 88376 AND
Enter value for res_id: 990
old  11: RESOURCE_ID = &RES_ID AND
new  11: RESOURCE_ID = 990 AND
Enter value for res_seq_num: 100
old  12: RESOURCE_SEQ_NUM = &RES_SEQ_NUM
new  12: RESOURCE_SEQ_NUM = 100
no rows selected
Enter value for rout_seq_id: 19948
old   9: ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: ROUTING_SEQUENCE_ID = 19948 AND
Enter value for op_seq_id: 88376
old  10: OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: OPERATION_SEQUENCE_ID = 88376 AND
Enter value for res_id: 990
old  11: RESOURCE_ID = &RES_ID
new  11: RESOURCE_ID = 990
       SSN         BT UC          PF
---------- ---------- --- ----------
       100          1 Hr           2
       100          1 Hr           2
Enter value for rout_seq_id: 19948
old   9: ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: ROUTING_SEQUENCE_ID = 19948 AND
Enter value for op_seq_id: 88376
old  10: OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: OPERATION_SEQUENCE_ID = 88376 AND
Enter value for res_id: 990
old  11: RESOURCE_ID = &RES_ID
new  11: RESOURCE_ID = 990
SCHEDULE_SEQ_NUM    ALT_NUM RESOURCE_SEQ_NUM
---------------- ---------- ----------------
             100          0               40
             100          0               60
Enter value for res_id: 990
old   8: RESOURCE_ID = (&RES_ID/2) AND
new   8: RESOURCE_ID = (990/2) AND
Enter value for op_seq_id: 88376
old   9: OPERATION_SEQUENCE_ID = (&OP_SEQ_ID/2)
new   9: OPERATION_SEQUENCE_ID = (88376/2)
SCHEDULE_SEQ_NUM RESOURCE_SEQ_NUM SCHEDULE_FLAG
---------------- ---------------- -------------
             100               40             1
             100               60             1
Enter value for res_id: 990
old   9: RESOURCE_ID = (&RES_ID/2) AND
new   9: RESOURCE_ID = (990/2) AND
Enter value for op_seq_id: 88376
old  10: OPERATION_SEQUENCE_ID = (&OP_SEQ_ID/2)
new  10: OPERATION_SEQUENCE_ID = (88376/2)
no rows selected
 
SQL> @check.sql
Enter value for rout_seq_id: 339436
ROUTING_SEQUENCE_ID = 339436
Enter value for op_seq_id: 758252
OPERATION_SEQUENCE_ID = 758252
Enter value for res_seq_num: 100
RESOURCE_SEQ_NUM = 100
Enter value for res_id: 1020
RESOURCE_ID = 1020
Enter value for rout_seq_id: 339436
old   9: ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: ROUTING_SEQUENCE_ID = 339436 AND
Enter value for op_seq_id: 758252
old  10: OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: OPERATION_SEQUENCE_ID = 758252 AND
Enter value for res_id: 1020
old  11: --RESOURCE_ID = &RES_ID --AND
new  11: --RESOURCE_ID = 1020 --AND
Enter value for res_seq_num: 100
old  12: RESOURCE_SEQ_NUM = &RES_SEQ_NUM
new  12: RESOURCE_SEQ_NUM = 100
no rows selected
Enter value for rout_seq_id: 339436
old   9: --ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: --ROUTING_SEQUENCE_ID = 339436 AND
Enter value for op_seq_id: 758252
old  10: --OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: --OPERATION_SEQUENCE_ID = 758252 AND
Enter value for res_id: 1020
old  11: RESOURCE_ID = &RES_ID AND
new  11: RESOURCE_ID = 1020 AND
Enter value for res_seq_num: 100
old  12: RESOURCE_SEQ_NUM = &RES_SEQ_NUM
new  12: RESOURCE_SEQ_NUM = 100
no rows selected
Enter value for rout_seq_id: 339436
old   9: ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: ROUTING_SEQUENCE_ID = 339436 AND
Enter value for op_seq_id: 758252
old  10: OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: OPERATION_SEQUENCE_ID = 758252 AND
Enter value for res_id: 1020
old  11: RESOURCE_ID = &RES_ID
new  11: RESOURCE_ID = 1020
       SSN         BT UC          PF
---------- ---------- --- ----------
       100          1 Hr           2
       100          1 Hr           2
Enter value for rout_seq_id: 339436
old   9: ROUTING_SEQUENCE_ID = &ROUT_SEQ_ID AND
new   9: ROUTING_SEQUENCE_ID = 339436 AND
Enter value for op_seq_id: 758252
old  10: OPERATION_SEQUENCE_ID = &OP_SEQ_ID AND
new  10: OPERATION_SEQUENCE_ID = 758252 AND
Enter value for res_id: 1020
old  11: RESOURCE_ID = &RES_ID
new  11: RESOURCE_ID = 1020
SCHEDULE_SEQ_NUM    ALT_NUM RESOURCE_SEQ_NUM
---------------- ---------- ----------------
             100          0               60
             100          0               70
Enter value for res_id: 1020
old   8: RESOURCE_ID = (&RES_ID/2) AND
new   8: RESOURCE_ID = (1020/2) AND
Enter value for op_seq_id: 758252
old   9: OPERATION_SEQUENCE_ID = (&OP_SEQ_ID/2)
new   9: OPERATION_SEQUENCE_ID = (758252/2)
SCHEDULE_SEQ_NUM RESOURCE_SEQ_NUM SCHEDULE_FLAG
---------------- ---------------- -------------
             100               60             1
             100               70             1
Enter value for res_id: 1020
old   9: RESOURCE_ID = (&RES_ID/2) AND
new   9: RESOURCE_ID = (1020/2) AND
Enter value for op_seq_id: 758252
old  10: OPERATION_SEQUENCE_ID = (&OP_SEQ_ID/2)
new  10: OPERATION_SEQUENCE_ID = (758252/2)
no rows selected
 
 
注意这里的RESOURCE_SEQ_NUM(资源序号),脚本要求输入的四个变量从请求日志获得。
这个例子的变量值可能跟日志的不匹配,因为跑了两次ASCP,我取的不是最新的日志。接着看一下ORACLE提供的解决方案:
 
The SCHEDULE_SEQ_NUM must be different for the two lines in the routing that are simultaneously scheduled and have different basis
types.
Manually update the schedule sequence number to a unique number for this item/routing/operation combination,
via Help -> Diagnostics->Examine
Validate the resources that are simultaneously scheduled and then Query for SCHEDULE_SEQ_
NUM and change it to a unique number, then press OK
In your system SCHEDULE_SEQ_NUM is duplicated, please manually update the schedule sequence number to a unique one.
 
具体操作如下:
 
Please look at the routing for the item. In one of the organizations, there is a resource which was s
etup twice on the same routing operation and scheduling sequence of the item.
Look at the routing and routing operation for the item. In the operation, there is
a resource which is listed that has two rows. Look at:
Help-> Diagnostics -> Examine
The resource has the same SCHEDULE_SEQ_NUM.
Please either delete one row for the resource, combine the two resource sequences into one resource sequence, or change the schedule sequence number to unique one.
 
具体解释:
SQL>select * from xxcux.cux_routing_resource_v where OPERATION_SEQUENCE_ID=385132
 
--注意这里的385132=(&OP_SEQ_ID/2)=(770264/2)。cux_routing_resource_v的定义如下:
SELECT M1.SEGMENT1,T1.ASSEMBLY_ITEM_ID,T1.ORGANIZATION_ID,T2.OPERATION_SEQ_NUM,T2.STANDARD_OPERATION_CODE,T2.OPERATION_DESCRIPTION
    ,T3.RESOURCE_CODE,T3.USAGE_RATE_OR_AMOUNT
    ,t1.ROUTING_SEQUENCE_ID,t2.OPERATION_SEQUENCE_ID
    ,t3.RESOURCE_SEQ_NUM
    ,t3.SCHEDULE_SEQ_NUM ,T1.LINE_CODE,T3.ASSIGNED_UNITS
    ,t3.BASIS_TYPE,t3.SCHEDULE_FLAG,M1.DESCRIPTION ,bv.DESCRIPTION res_desc,USAGE_RATE_OR_AMOUNT_INVERSE
    FROM APPS.BOM_OPERATIONAL_ROUTINGS_V T1
      ,APPS.BOM_OPERATION_SEQUENCES_V T2
   ,APPS.BOM_OPERATION_RESOURCES_V T3
   ,INV.MTL_SYSTEM_ITEMS_B M1
   ,apps.BOM_RESOURCES_V bv
    WHERE T1.ROUTING_SEQUENCE_ID=T2.ROUTING_SEQUENCE_ID
       AND T2.OPERATION_SEQUENCE_ID=T3.OPERATION_SEQUENCE_ID
    AND M1.INVENTORY_ITEM_ID=T1.ASSEMBLY_ITEM_ID
    and m1.ORGANIZATION_ID=t1.ORGANIZATION_ID
    and bv.RESOURCE_CODE=t3.RESOURCE_CODE
    and bv.ORGANIZATION_ID=m1.ORGANIZATION_ID
    and t2.DISABLE_DATE is null

最后这个查询返回7条记录。其中segment1这个字段对应的就是具体物料。由具体物料我们可以找到工艺路线:
BOM->ROUTING->ROUTING->选择组织。点击工序下的序号再点击工序资源进入工序资源的FORM。
单击计划我们可以看到问题所在。再资源这一列有相同的资源定义。询问业务部门的同事得到的说法是:
同一个工艺路线里面可以有重复的资源,但是工序不能相同。但是按照ORACLE的说法:
Please either delete one row for the resource,
combine the two resource sequences into one resource sequence,
or change the schedule sequence number to unique one.
好像是说同一个工序里可以定义相同的资源但计划序号(schedule sequence number )要唯一。
这里资源序号为40,60的资源是相同的资源。业务部门将40的资源进行删除。重新跑计划数据收集问题解决!
 
 
阅读(3172) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~