Oracle EBS 更新客户地点
--更新客户地点
declare
x_return_status VARCHAR2(150);
x_msg_count NUMBER;
x_msg_data VARCHAR2(2000);
x_profile_id NUMBER;
l_location_id NUMBER;
l_object_version_number NUMBER;
l_party_rec hz_party_site_v2pub.party_site_rec_type;
cursor cur_DT is
SELECT loc.location_id,
loc.object_version_number,
addr.PARTY_SITE_ID,
hc.ACCOUNT_NUMBER,
hc.CUST_ACCOUNT_ID,
party_site.PARTY_SITE_NAME,
hcp.CUST_ACCOUNT_PROFILE_ID,
hcp.CREDIT_HOLD,
hc.CREATION_DATE,
hc.CREATED_BY,
hc.ORIG_SYSTEM_REFERENCE,
hc.PARTY_ID,
addr.status status1,
party_site.STATUS status2
FROM hz_cust_acct_sites_all addr,
hz_party_sites party_site,
hz_locations loc,
HZ_CUSTOMER_PROFILES hcp,
HZ_CUST_ACCOUNTS hc
WHERE 1 = 1
AND addr.party_site_id = party_site.party_site_id
AND loc.location_id = party_site.location_id
and hc.PARTY_ID = party_site.PARTY_ID
and hc.CUST_ACCOUNT_ID = hcp.CUST_ACCOUNT_ID
and party_site.PARTY_ID =
(select hz.PARTY_ID
from hz_parties hz
where hz.PARTY_ID = party_site.PARTY_ID
and hz.PARTY_NUMBER = ''); begin
fnd_global.apps_initialize(0, 50738, 20003);
mo_global.init('AR');
FOR rec IN CUR_DT LOOP
begin
select hc.OBJECT_VERSION_NUMBER
into l_object_version_number
from hz_party_sites hc
where hc.PARTY_ID = rec.PARTY_ID;
end;
l_party_rec.party_id := rec.party_id;
l_party_rec.PARTY_SITE_ID := rec.PARTY_SITE_ID;
l_party_rec.status := 'I';
l_party_rec.location_id := rec.location_id; hz_party_site_v2pub.update_party_site(p_init_msg_list => fnd_api.g_false,
p_party_site_rec => l_party_rec,
p_object_version_number => l_object_version_number,
x_return_status => x_return_status,
x_msg_count => x_msg_count,
x_msg_data => x_msg_data); IF x_return_status = fnd_api.g_ret_sts_error THEN
x_msg_count := fnd_msg_pub.count_msg;
x_msg_data := substr(fnd_msg_pub.get(fnd_msg_pub.g_first,
fnd_api.g_false),
1,
512);
dbms_output.put_line(x_msg_data);
fnd_msg_pub.delete_msg();
RAISE fnd_api.g_exc_error;
ELSIF x_return_status = fnd_api.g_ret_sts_unexp_error THEN
x_msg_count := fnd_msg_pub.count_msg;
x_msg_data := substr(fnd_msg_pub.get(fnd_msg_pub.g_first,
fnd_api.g_false),
1,
512);
dbms_output.put_line(x_msg_data); fnd_msg_pub.delete_msg();
RAISE fnd_api.g_exc_unexpected_error;
END IF;
IF x_return_status = fnd_api.g_ret_sts_success THEN
dbms_output.put_line('------------------Update Success-------------------'); END IF;
END LOOP;
END;
Oracle EBS 更新客户地点的更多相关文章
- Oracle EBS R12 客户表结构
参考链接: Oracle EBS R12 客户表结构 Oracle EBS中的“客户”."客户地点".‘订单’之间的关系 Oracle EBS中的“客户”."客户地点&q ...
- Oracle EBS AP 供应商地点失效
/* 供应商地点失效 creation: created by jenrry 20161108 1.00 */ DECLARE lv_return_status ) := NULL; ln_msg_c ...
- Oracle EBS AR 客户API
------------------------------------ 1. Set Environment ------------------------------------ -- 1a. ...
- Oracle EBS AR 客户取数SQL
SELECT acct.cust_account_id, acct.party_id, acct.account_number, party.party_name, lkp1.meaning part ...
- Oracle EBS 查询客户报错 查询已超出 200 行。可能存在更多的行,请限制查询。
- [转]oracle EBS 基础100问
from:http://www.cnblogs.com/xiaoL/p/3593691.html http://f.dataguru.cn/thread-51057-1-1.html 1001 OR ...
- Oracle EBS R12经验谈(二)
作者: jianping.ni 时间: 2009-2-13 12:52 标题: Oracle EBS R12经验谈(二) OAF页面:银行帐户开户人LOV值列表无值 在输入 应付超 ...
- ORACLE EBS常用表
http://www.cnblogs.com/quanweiru/archive/2012/09/26/2704628.html call fnd_global.APPS_INITIALIZE(131 ...
- Oracle EBS R12 (12.1.3) Installation Linux(64 bit)
Oracle EBS R12 (12.1.3) Installation Linux(64 bit) Contents Objective. 3 1 Download & Unzip. 3 D ...
随机推荐
- 【数组】Container With Most Water
题目: Given n non-negative integers a1, a2, ..., an, where each represents a point at coordinate (i, a ...
- Android4.0 Launcher 源码分析3——WorkSpace结构(滑动)
3.WorkSpace结构(滑动) 桌面的左右滑动功能主要是在PagedView类中实现的,而WorkSpace是PagedView类的子类,所以会继承PagedView中的方法.当我们的手指点击Wo ...
- Android 开发工具类 26_getFile
从网络获取可执行文件 public void getFile() throws Exception{ // 首先得到请求的路径 String urlpath = "http://ftpcnc ...
- protocol buffers生成go代码原理
本文描述了protocol buffers使用.proto文件生成pb.go文件的过程 编译器 编译器需要插件来编译环境,使用如下方式安装插件:go get github.com/golang/pro ...
- 数据库报错com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for column 'ua' at row 1
记一次报错记录,成长路上的点滴 明明使用浏览器或者微信开发工具调试接口没有问题,但是在真机测试时候就出问题了.(((¬_¬)) 500服务器内部错误,要死的节奏啊 登陆tomcat服务器 使用命令ta ...
- mongodb-手写mongoclient加入到springmvc中
由于一个项目使用的是springmvc3.x版本, mongodb使用的为3.x版本, 所以springmvc继承的mongodb-data并不可用, 只能自己手写一个mongoclient并加入到s ...
- 分布式ID生成方法-趋势有序的全局唯一ID
一.需求缘起 几乎所有的业务系统,都有生成一个记录标识的需求,例如: (1)消息标识:message-id (2)订单标识:order-id (3)帖子标识:tiezi-id 这个记录标识往往就是数据 ...
- ASP .NET Core 基本知识点示例 目录
ASP.NET Core 的 运行机制 文章 ASP.NET Core 中的 配置 文章 源代码 ASP.NET Core 中的 依赖注入 文章 源代码 ASP.NET Core 中的 日志 文章 源 ...
- 关于 AXI协议的学习解释说明
AXI(Advanced eXtensible Interface)是一种总线协议,该协议是ARM公司提出的AMBA(Advanced Microcontroller Bus Architecture ...
- Maven Debug
1.在pom.xml中新增plugin <plugin> <groupId>org.mortbay.jetty</groupId> <artifact ...