供应商API补充(详解EBS接口开发之供应商导入)(转)
原文地址 供应商导入的API补充(详解EBS接口开发之供应商导入)
--供应商
--创建
AP_VENDOR_PUB_PKG.Create_Vendor
( p_api_version IN NUMBER,
p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
p_commit IN VARCHAR2 := FND_API.G_FALSE,
p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2,
p_vendor_rec IN r_vendor_rec_type,
x_vendor_id OUT NOCOPY AP_SUPPLIERS.VENDOR_ID%TYPE,
x_party_id OUT NOCOPY HZ_PARTIES.PARTY_ID%TYPE
);
--更新
AP_VENDOR_PUB_PKG.Update_Vendor
( p_api_version IN NUMBER,
p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
p_commit IN VARCHAR2 := FND_API.G_FALSE,
p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2,
p_vendor_rec IN r_vendor_rec_type,
p_vendor_id IN NUMBER
);
--亲们,提供个R12失效供应商的程序供参考:
DECLARE
--
lv_return_status VARCHAR2(1);
lv_msg_count NUMBER;
lv_msg_data VARCHAR2(2000);
--
lv_vendor_id ap_suppliers.vendor_id%TYPE;
lv_vendor_rec AP_VENDOR_PUB_PKG.r_vendor_rec_type;
L_USER_ID NUMBER := 0;
L_RESP_ID NUMBER := 50192;
L_RESP_APPL_ID NUMBER := 20003;
--
cursor c_vendorid is
select vendor_id from TMP_DISABLE_VENDOR where STATUS='N'; BEGIN
--
EXECUTE IMMEDIATE 'ALTER session SET nls_language = ''American'''; fnd_global.apps_initialize(L_USER_ID, L_RESP_ID, L_RESP_APPL_ID);
mo_global.init('S');
--
for cc in c_vendorid loop
lv_vendor_id := cc.vendor_id;
lv_vendor_rec.END_DATE_ACTIVE :=SYSDATE; --如果要取消失效时间,请设置为:FND_API.G_MISS_DATE;
--
AP_VENDOR_PUB_PKG.Update_Vendor(p_api_version => 1.0
,p_init_msg_list => fnd_api.g_true
,p_commit => fnd_api.g_false
,p_validation_level => fnd_api.g_valid_level_full
,x_return_status => lv_return_status
,x_msg_count => lv_msg_count
,x_msg_data => lv_msg_data
,p_vendor_rec => lv_vendor_rec
,p_vendor_id => lv_vendor_id);
-- -- dbms_output.put_line(lv_return_status || '-' || lv_msg_count || '-' || lv_msg_data);
--
UPDATE TMP_DISABLE_VENDOR
SET STATUS ='Y'
WHERE vendor_id = lv_vendor_id;
end loop;
COMMIT;
END;
--验证
AP_VENDOR_PUB_PKG.Validate_Vendor
( p_api_version IN NUMBER,
p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
p_commit IN VARCHAR2 := FND_API.G_FALSE,
p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2,
p_vendor_rec IN OUT NOCOPY r_vendor_rec_type,
p_mode IN VARCHAR2,
p_calling_prog IN VARCHAR2,
x_party_valid OUT NOCOPY VARCHAR2,
x_payee_valid OUT NOCOPY VARCHAR2,
p_vendor_id IN NUMBER
);
--供应商地点
--创建
AP_VENDOR_PUB_PKG.Create_Vendor_Site
( p_api_version IN NUMBER,
p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
p_commit IN VARCHAR2 := FND_API.G_FALSE,
p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2,
p_vendor_site_rec IN r_vendor_site_rec_type,
x_vendor_site_id OUT NOCOPY NUMBER,
x_party_site_id OUT NOCOPY NUMBER,
x_location_id OUT NOCOPY NUMBER
);
--更新
AP_VENDOR_PUB_PKG.Update_Vendor_Site
( p_api_version IN NUMBER,
p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
p_commit IN VARCHAR2 := FND_API.G_FALSE,
p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2,
p_vendor_site_rec IN r_vendor_site_rec_type,
p_vendor_site_id IN NUMBER,
p_calling_prog IN VARCHAR2 DEFAULT 'NOT ISETUP'
);
--验证
AP_VENDOR_PUB_PKG.Validate_Vendor_Site
( p_api_version IN NUMBER,
p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
p_commit IN VARCHAR2 := FND_API.G_FALSE,
p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2,
p_vendor_site_rec IN OUT NOCOPY r_vendor_site_rec_type,
p_mode IN VARCHAR2,
p_calling_prog IN VARCHAR2,
x_party_site_valid OUT NOCOPY VARCHAR2,
x_location_valid OUT NOCOPY VARCHAR2,
x_payee_valid OUT NOCOPY VARCHAR2,
p_vendor_site_id IN NUMBER
);
--供应商联系人
--创建
AP_VENDOR_PUB_PKG.Create_Vendor_Contact
( p_api_version IN NUMBER,
p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
p_commit IN VARCHAR2 := FND_API.G_FALSE,
p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2,
p_vendor_contact_rec IN r_vendor_contact_rec_type,
x_vendor_contact_id OUT NOCOPY NUMBER,
x_per_party_id OUT NOCOPY NUMBER,
x_rel_party_id OUT NOCOPY NUMBER,
x_rel_id OUT NOCOPY NUMBER,
x_org_contact_id OUT NOCOPY NUMBER,
x_party_site_id OUT NOCOPY NUMBER
);
--更新
AP_VENDOR_PUB_PKG.Update_Vendor_Contact
( p_api_version IN NUMBER,
p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE ,
p_commit IN VARCHAR2 := FND_API.G_FALSE,
p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL,
p_vendor_contact_rec IN r_vendor_contact_rec_type,
x_return_status OUT NOCOPY VARCHAR2 ,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2
);
--验证
AP_VENDOR_PUB_PKG.Validate_Vendor_Contact
( p_api_version IN NUMBER,
p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
p_commit IN VARCHAR2 := FND_API.G_FALSE,
p_validation_level IN NUMBER := FND_API.G_VALID_LEVEL_FULL,
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2,
p_vendor_contact_rec IN OUT NOCOPY r_vendor_contact_rec_type,
x_rel_party_valid OUT NOCOPY VARCHAR2,
x_per_party_valid OUT NOCOPY VARCHAR2,
x_rel_valid OUT NOCOPY VARCHAR2,
x_org_party_id OUT NOCOPY NUMBER,
x_org_contact_valid OUT NOCOPY VARCHAR2,
x_location_id OUT NOCOPY NUMBER,
x_party_site_valid OUT NOCOPY VARCHAR2
);
--导入供应商
--供应商
AP_VENDOR_PUB_PKG.Import_Vendors
( p_api_version IN NUMBER,
p_source IN VARCHAR2 DEFAULT 'IMPORT',
p_what_to_import IN VARCHAR2 DEFAULT NULL,
p_commit_size IN NUMBER DEFAULT 1000,
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2
);
--地点
AP_VENDOR_PUB_PKG.Import_Vendor_Sites
( p_api_version IN NUMBER,
p_source IN VARCHAR2 DEFAULT 'IMPORT',
p_what_to_import IN VARCHAR2 DEFAULT NULL,
p_commit_size IN NUMBER DEFAULT 1000,
p_org_id IN NUMBER DEFAULT NULL, --bug13801271
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2
);
--联系人
AP_VENDOR_PUB_PKG.Import_Vendor_Contacts
( p_api_version IN NUMBER,
p_source IN VARCHAR2 DEFAULT 'IMPORT',
p_what_to_import IN VARCHAR2 DEFAULT NULL,
p_commit_size IN NUMBER DEFAULT 1000,
x_return_status OUT NOCOPY VARCHAR2,
x_msg_count OUT NOCOPY NUMBER,
x_msg_data OUT NOCOPY VARCHAR2
);
供应商API补充(详解EBS接口开发之供应商导入)(转)的更多相关文章
- 详解EBS接口开发之供应商导入
(一)供应商常用标准表简介 1.1 常用标准表 如下表中列出了与供应商相关的表和说明: 表名 说明 其他信息 ap_suppliers 供应商头表 供应商的头信息如:供应商名.供应商编码.税号等 ...
- 供应商导入的API补充(详解EBS接口开发之供应商导入)
--供应商 --创建 AP_VENDOR_PUB_PKG.Create_Vendor ( p_api_version IN NUMBER, p_init_msg_list IN VARCHAR2 := ...
- 详解EBS接口开发之供应商导入(补充)--供应商银行账户更新
CREATE OR REPLACE PACKAGE BODY update_vendor_account IS PROCEDURE main(errbuf OUT VARCHAR2, retcode ...
- 详解EBS接口开发之供应商导入(补充)--错误信息处理
check reject details on records of AP_SUPPLIER_INT SELECT s.parent_table,s.reject_lookup_code,S.LAST ...
- 详解EBS接口开发之供应商导入补充-供应商地点增加实例
DECLARE --v_org_id number; v_vendor_interface_id NUMBER; v_vendor_site_interface_id NUMBER; --接口表的id ...
- 详解EBS接口开发之物料导入API
create_item inv_item_grp.create_item(p_commit => fnd_api.g_true, -- p_item_rec => l_item_rec, ...
- 详解EBS接口开发之库存事务处理采购接收--补充
除了可以用 详解EBS接口开发之库存事务处理采购接收的方法还可以用一下方法,不同之处在于带有批次和序列控制的时候实现方式不同 The script will load records into ...
- 详解EBS接口开发之采购申请导入
更多内容可以参考我的博客 详解EBS接口开发之采购订单导入 http://blog.csdn.net/cai_xingyun/article/details/17114697 /*+++++++ ...
- 详解EBS接口开发之库存事务处理批次更新
库存事务处理批次有时候出现导入错误需要更新可使用次程序更新,批次导入可参考博客 详解EBS接口开发之库存事务处理-物料批次导入 http://blog.csdn.net/cai_xingyun/art ...
随机推荐
- Python Web学习笔记之Python多线程基础
多线程理解 多线程是多个任务同时运行的一种方式.比如一个循环中,每个循环看做一个任务,我们希望第一次循环运行还没结束时,就可以开始第二次循环,用这种方式来节省时间. python中这种同时运行的目的是 ...
- 02: css常用属性
目录: 1.1 设置样式的七个选择器 1.2 css常见属性浅析 1.3 css布局中常用方法 1.1 设置样式的七个选择器返回顶部 1.其中选择器介绍 1. 直接在标签里的style标签写样式 2. ...
- 20165310 学习基础和C语言基础调查
学习基础和C语言基础调查 做中学体会 阅读做中学之后,了解老师关于五笔练习.减肥.乒乓和背单词的经历,不禁联想到自己学古筝的经历. 成功的经验 兴趣 我其实小时候学过一段时间古筝,但是那时候是因为父母 ...
- Disruptor学习笔记(一):基本原理和概念
一.Disruptor基本原理 在多线程开发中,我们常常遇到这样一种场景:一些线程接受用户请求,另外一些线程处理这些请求.比如日志处理中的日志输入和告警.这种典型的生产者消费者场景十分常见,而生产者消 ...
- C# 将 Stream 写入文件
public void StreamToFile(Stream stream,string fileName) { // 把 Stream 转换成 byte[] byte[] bytes = new ...
- arm linux下编译库System.Net.Primitives.dll和System.Xml.XmlSerializer.dll
1.环境: /home/jello # uname -aLinux 3.10.0 #2 SMP Mon Mar 6 17:52:09 CST 2017 armv7l GNU/Linux 2.获取mo ...
- 奖券数目|2015年蓝桥杯B组题解析第一题-fishers
奖券数目 有些人很迷信数字,比如带"4"的数字,认为和"死"谐音,就觉得不吉利. 虽然这些说法纯属无稽之谈,但有时还要迎合大众的需求.某抽奖活动的奖券号码是5位 ...
- POJ 3687 Labeling Balls(拓扑排序)题解
Description Windy has N balls of distinct weights from 1 unit to N units. Now he tries to label them ...
- 【第三十章】 elk(1) - 第一种架构(最简架构)
软件版本: es:2.4.0 logstash:2.4.0 kibana:4.6.1 一.logstash安装(收集.过滤日志.构建索引) 1.下载:https://www.elastic.co/do ...
- UVa 10766 Organising the Organisation(矩阵树定理)
https://vjudge.net/problem/UVA-10766 题意: 给出n, m, k.表示n个点,其中m条边不能直接连通,求生成树个数. 思路: 这也算个裸题,把可以连接的边连接起来, ...