The error Unhandled Script Exception: Object has no reference. EXCEPTION_CLASS_SCRIPT_BAD_PARAM SCRIPT_CMD_DEFEF_TABLE appears when I try to add items to a stock count schedule. What should I do?
In the Item Quantity Master table (IV00102) there is a column RCRDTYPE that should have a value of 1 where the LOCNCODE is blank and a value of 2 where the LOCNCODE has a value. If there is an item that has a value of 2 where there is a blank LOCNCODE or an item that has a value of 1 where there is a LOCNCODE, the error will appear. If this is the case, one of the following solutions will correct the problem:
1) Unassign the item from the site that has the incorrect value by performing the following steps:
• Go to Item Quantities Maintenance (Cards - Inventory - Qtys/Sites).
• Select the item and the site. The quantities will need to be zero.
• Choose Delete .
2) If you are using Microsoft SQL, the RCRDTYPE value could be updated in Query Analyzer with a script similar to the following (make a backup first):
Update IV00102 set RCRDTYPE=2 where DEX_ROW_ID=XX
3) If you are using Ctree or Pervasive SQL and the item can not be unassigned from the site, you would need to use some sort of database tool to change the value in the IV00102 file.
This article was TechKnowledge Document ID: 25918