Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

EBS uses API to update material properties Inv_Item_Grp

2025-04-10 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

Use the standard API Inv_Item_Grp to update item attributes. You can modify most fields, including item code, item description and other attributes.

Unmodifiable fields:PRIMARY_UNIT_OF_MEASURE, TRACKING_QUANTITY_IND, ONT_PRICING_QTY_SOURCE, SECONDARY_UNIT_CODE, SECONDARY_DEFAULT_IND, DUAL_UNIT_DEVIATION_HIGH, DUAL_UNIT_DEVIATION_LOW and ENGINEERING_ITEM_FLAG.

The script is as follows:

DECLARE l_Item_Rec Inv_Item_Grp.Item_Rec_Type; x_Item_Rec Inv_Item_Grp.Item_Rec_Type; x_Error_Tbl Inv_Item_Grp.Error_Tbl_Type; x_Return_Status VARCHAR2(1);BEGIN Fnd_Global.Apps_Initialize(User_Id => 0, Resp_Id => 20634, Resp_Appl_Id => 401); --Item l_Item_Rec.Inventory_Item_Id := 3374628; l_Item_Rec.Organization_Id := 176; --Modifiable: l_Item_Rec.Segment1 := 'CCITSpeed001-1'; --Non-modifiable fields:PRIMARY_UNIT_OF_MEASURE, TRACKING_QUANTITY_IND, ONT_PRICING_QTY_SOURCE, SECONDARY_UNIT_CODE, SECONDARY_DEFAULT_IND, DUAL_UNIT_DEVIATION_HIGH, DUAL_UNIT_DEVIATION_LOW and ENGINEERING_ITEM_FLAG --API Inv_Item_Grp.Update_Item(p_Commit => Fnd_Api.g_False, p_Item_Rec => l_Item_Rec, x_Item_Rec => x_Item_Rec, x_Return_Status => x_Return_Status, x_Error_Tbl => x_Error_Tbl); Dbms_Output.Put_Line('x_Return_Status:' || x_Return_Status); --Result IF x_Return_Status Fnd_Api.g_Ret_Sts_Success THEN -- ROLLBACK; FOR i IN 1 .. x_Error_Tbl.Count LOOP Dbms_Output.Put_Line('Transaction ID :' || x_Error_Tbl(i) .Transaction_Id); Dbms_Output.Put_Line('Unique ID :' || x_Error_Tbl(i) .Unique_Id); Dbms_Output.Put_Line('Message Name :' || x_Error_Tbl(i) .Message_Name); Dbms_Output.Put_Line('Message Text: :' || x_Error_Tbl(i) .Message_Text); Dbms_Output.Put_Line('Table Name :' || x_Error_Tbl(i) .Table_Name); Dbms_Output.Put_Line('Column Name :' || x_Error_Tbl(i) .Column_Name); Dbms_Output.Put_Line('Organization ID :' || x_Error_Tbl(i) .Organization_Id); END LOOP; IF (x_Return_Status = Fnd_Api.g_Ret_Sts_Unexp_Error) THEN RAISE Fnd_Api.g_Exc_Unexpected_Error; ELSIF (x_Return_Status = Fnd_Api.g_Ret_Sts_Error) THEN RAISE Fnd_Api.g_Exc_Error; END IF; ELSE -- COMMIT; Dbms_Output.Put_Line('ok:' || x_Item_Rec.Item_Number); END IF;END;

Tested.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report