Applies to:

Oracle Inventory Management - Version: 12.0.6<max_ver> and later   [Release: 12 and later ]
Information in this document applies to any platform.
***Checked for relevance on 7-Sep-2011***

Goal

In Release 12, Subledger Accounting has been introduced for Procurement.  As a part of Subledger Accounting, new SLA tables XLA_AE_HEADERS, XLA_AE_LINES and XLA_DISTRIBUTION_LINKS have been introduced.

How to join the tables XLA_AE_HEADERS with RCV_TRANSACTIONS?

Solution

There is no direct join between these 2 tables, however you can link via other tables and return
data.

In the rcv_receiving_sub_ledger with the rcv_transaction_id you can tie in the rcv_transactions
table with the transaction_id, so:

rrsl.rcv_transaction_id = rt.transaction_id

In the rcv_receiving_sub_ledger with the RCV_SUB_LEDGER_ID you can tie in the
XLA_DISTRIBUTION_LINKS table with the SOURCE_DISTRIBUTION_ID_NUM_1:

xdl.SOURCE_DISTRIBUTION_ID_NUM_1 = rrsl.RCV_SUB_LEDGER_ID

And then complete the join between the tables with the ae_header_id reference between
xla_ae_headers and XLA_DISTRIBUTION_LINKS:

aeh.ae_header_id = xdl.ae_header_id

So with the following completed script by entering an accrued receipt number you can obtain the
rcv_transaction transaction_id and the xla_ae_headers table ae_header_id values, thus effectively joining the respective tables.

Please note however that the transactions must have been accrued and the Create Accounting process have completed for records to be seen in the Subledger Tables.   Here is the script, it requires the entry of a receipt number and the appropriate set of books id ( for a receipt that has been accrued as described above):

SELECT aeh.ae_header_id,
ael.ae_line_num,
ael.accounting_class_code,
ael.accounted_dr,
ael.accounted_cr,
rt.transaction_id,
rt.shipment_header_id
FROM xla_ae_headers aeh,
xla_ae_lines ael,
rcv_transactions rt,
xla_distribution_links xdl,
rcv_receiving_sub_ledger rrsl
WHERE aeh.ae_header_id = xdl.ae_header_id
AND aeh.ae_header_id = ael.ae_header_id
AND ael.ae_header_id = xdl.ae_header_id
AND ael.ae_line_num = xdl.ae_line_num
AND xdl.source_distribution_type = 'RCV_RECEIVING_SUB_LEDGER'
AND xdl.source_distribution_id_num_1 = rrsl.rcv_sub_ledger_id
AND rrsl.rcv_transaction_id = rt.transaction_id
AND rrsl.set_of_books_id = &set_of_books_id
AND rt.shipment_header_id IN (SELECT shipment_header_id
FROM rcv_shipment_headers
WHERE receipt_num = '&RECEIPT_NUM')
ORDER BY rt.transaction_id,
ael.ae_header_id,
ael.ae_line_num;

How To Join XLA_AE_HEADERS and RCV_TRANSACTIONS? [ID 558514.1]的更多相关文章

  1. How To Join XLA_AE_HEADERS and RCV_TRANSACTIONS(子分类账到事务处理追溯)

    Applies to:   Oracle Inventory Management - Version: 12.0.6<max_ver> and later   [Release: 12 ...

  2. 内连接查询 (select * from a join b on a.id = b.id) 与 关联查询 (select * from a , b where a.id = b.id)的区别

    转自https://blog.csdn.net/l690781365/article/details/76261093 1.首先了解 on .where 的执行顺序以及效率? from a join ...

  3. MySQL JOIN 连接时,条件为以逗号分隔的字段与 ID 相匹配

    一.背景 有一张相片表,一张相片所属标签表,一张相片可以归属于多个标签,表结构如下: 现在需要通过一次查询,得到每一张照片对应的标签名称,标签名称之间以固定的分隔符连接,结果如下图: 二.查询语句 原 ...

  4. linq lambda left join

    //var list = table1.Join(table2, ee => ee.Id, ff => ff.table1_Id, (ee, ff) => new { ee, ff  ...

  5. 30秒懂SQL中的join(2幅图+30秒)

    废话不多说,直接上图秒懂. t1表的结构与数据如下: t2表的结构与数据如下: inner join select * from t1 inner join t2 on t1.id = t2.id; ...

  6. Delete,Update与LEFT Join

    UPDATE:UPDATE A SET ApproverID=NULL FROM [SH_MaterialApplyBuyBill] A LEFT JOIN [SH_MaterialApplyBuyB ...

  7. inner join on 和 where = 的区别!

    请看下面两条语句:select * from table1 inner join table2 on table1.id = table2.idselect * from table1,table2 ...

  8. UPDATE INNER JOIN 两表联合更新

    UPDATE B_READMETER_HANDWORK INNER JOIN B_READMETER_ORDER_SP ON B_READMETER_HANDWORK.ID = B_READMETER ...

  9. SQL update join on 连接更新

    http:/how-can-i-do-an-update-statement-with-join-in-sql create table sale ( id int, udid int, assid ...

随机推荐

  1. VMware安装CentOS

    centos镜像地址:https://www.centos.org/download/ VMware版本:12.5.2 build-4638234 创建新的虚拟机 直接默认下一步 稍后安装操作系统-& ...

  2. JS案例之3——倒计时

    利用简单的数字累加循环模拟倒计时的效果,逻辑比较简单.如果大牛们有更好的办法欢迎补充. 这种效果经常用于在规定的时间做某件事.比如在1分钟之后重新发送验证码等. 案例演示: 源代码如下: <!D ...

  3. Vue.js——vue-router 60分钟快速入门

    概述 vue-router是Vue.js官方的路由插件,它和vue.js是深度集成的,适合用于构建单页面应用.vue的单页面应用是基于路由和组件的,路由用于设定访问路径,并将路径和组件映射起来.传统的 ...

  4. 浅谈SOA

    概念 wiki对于SOA定义如下: A service-oriented architecture (SOA) is a design pattern in which application com ...

  5. 2000条你应知的WPF小姿势 基础篇<69-73 WPF Freeze机制和Template>

    在正文开始之前需要介绍一个人:Sean Sexton. 来自明尼苏达双城的软件工程师.最为出色的是他维护了两个博客:2,000ThingsYou Should Know About C# 和 2,00 ...

  6. Linux网络编程系列-常见疑惑

    1.并发TCP最大连接数 一个TCP连接有一个四元组唯一标识{local_ip, local_port, remote_ip, remote_port} client端建立连接请求时,通常让系统分配一 ...

  7. Centos6.5中安装和配置vsftp详细总结

    一.vsftp安装篇 #查看是否安装:rpm -qa|grep vsftpd#卸载vsftpdrpm -e vsftpd-2.2.2-11.el6_3.1x86_64 --nodeps# 安装vsft ...

  8. Python学习--03变量类型

    变量赋值 Python中的变量不需要声明,变量的赋值操作既是变量声明和定义的过程. 每个变量在内存中创建,都包括变量的标识,名称和数据这些信息. 每个变量在使用前都必须赋值,变量赋值以后该变量才会被创 ...

  9. Vue 给子组件传递参数

    Vue 给子组件传递参数 首先看个例子吧 原文 html <div class="container" id="app"> <div clas ...

  10. redis成长之路——(六)

    redis配置 为了码农在代码上只关心业务以及代码上的统一性,wenli.drive.redis内部使用配置来完成那些不同的场景,也就是说随便填填配置就能适应不同的场景! 当然配置多了码农也会受不了, ...