-- 收款核销,贷项通知单核销也是通过ar_receivable_applications_all表
SELECT cr.receipt_number
,ad.amount_dr
,ad.amount_cr
,ad.source_table
,ad.source_type
,xla_oa_functions_pkg.get_ccid_description(gcc.chart_of_accounts_id
,ad.code_combination_id)
,ad.creation_date
FROM ar_distributions_all ad
,ar_receivable_applications_all ra
,ar_cash_receipts_all cr
,gl_code_combinations gcc
WHERE ad.source_table = 'RA'
AND ad.source_id = ra.receivable_application_id
AND ra.cash_receipt_id = cr.cash_receipt_id
AND gcc.code_combination_id = ad.code_combination_id
-- 收款记录
UNION ALL
SELECT cr.receipt_number
,ad.amount_dr
,ad.amount_cr
,ad.source_table
,ad.source_type
,xla_oa_functions_pkg.get_ccid_description(gcc.chart_of_accounts_id
,ad.code_combination_id)
,ad.creation_date
FROM ar_distributions_all ad
,ar_cash_receipt_history_all crh
,ar_cash_receipts_all cr
,gl_code_combinations gcc
WHERE ad.source_table = 'CRH'
AND ad.source_id = crh.cash_receipt_history_id
AND crh.cash_receipt_id = cr.cash_receipt_id
AND gcc.code_combination_id = ad.code_combination_id
ORDER BY creation_date;
  --杂项收款
SELECT cr.receipt_number,cr.cash_receipt_id
,ad.amount_dr
,ad.amount_cr
,ad.source_table
,ad.source_type
,xla_oa_functions_pkg.get_ccid_description(gcc.chart_of_accounts_id
,ad.code_combination_id)
,ad.creation_date
FROM ar_distributions_all ad
,ar_misc_cash_distributions_all mcd
,ar_cash_receipts_all cr
,gl_code_combinations gcc
WHERE ad.source_table = 'MCD'
AND ad.source_id = mcd.misc_cash_distribution_id
AND mcd.cash_receipt_id = cr.cash_receipt_id
AND gcc.code_combination_id = ad.code_combination_id;
   --应收总账日记账分录
SELECT h.je_source
,h.je_category
,fnd_flex_ext.get_segs('SQLGL', 'GL#', gcc.chart_of_accounts_id, l.code_combination_id) acct
,xla_oa_functions_pkg.get_ccid_description(gcc.chart_of_accounts_id
,l.code_combination_id) acct_descr
,l.entered_dr
,l.entered_cr
FROM gl_je_headers h
,gl_je_lines l
,gl_code_combinations gcc
,gl_period_statuses gps
WHERE h.je_header_id = l.je_header_id
AND l.code_combination_id = gcc.code_combination_id
AND h.je_source = 'Receivables'
AND l.period_name = gps.period_name;

Oracle EBS AR 收款取数的更多相关文章

  1. Oracle EBS AR 收款取值

    select hr.name, a.autoapply_flag, a.AUTOMATCH_SET_ID, a.LEGAL_ENTITY_ID, a.RECEIPT_NUMBER, a.type, a ...

  2. Oracle EBS AR 客户取数SQL

    SELECT acct.cust_account_id, acct.party_id, acct.account_number, party.party_name, lkp1.meaning part ...

  3. Oracle EBS AR 收款核销行关联到事务处理

    select ra.trx_number from ar_cash_receipts_all cr, ar_receivable_applications_all ar,ra_customer_trx ...

  4. Oracle EBS AR 收款API收款方法标识无效

    1.确认是不是没有收款方法 methods那个表的问题2.查看收款方法那个LOV的问题3.界面录入 是否会有问题  碰到的问题是 收款日期比较早时 找不到对应的收款方法 银行账户需要重新设置

  5. Oracle EBS AR 收款调整取值

    SELECT ct.trx_number ,adj.adjustment_number ,ad.amount_dr ,ad.amount_cr ,ad.source_table ,ad.source_ ...

  6. Oracle EBS AR 冲销收款

    DECLARE L_CR_ID NUMBER; L_ATTRIBUTE_REC AR_RECEIPT_API_PUB.ATTRIBUTE_REC_TYPE; L_GLOBAL_ATT_REC AR_R ...

  7. Oracle EBS AR 贷项通知单核销取值

    SELECT cm.trx_number ,fnd_flex_ext.get_segs('SQLGL', 'GL#', gcc.chart_of_accounts_id, ad.code_combin ...

  8. Oracle EBS AR应收核销取值

    AR_RECEIVABLE_APPLICATIONS APP, AR_CASH_RECEIPTS CR, AR_PAYMENT_SCHEDULES PS_INV, HZ_CUST_ACCOUNTS C ...

  9. Oracle EBS AR 其他API

    DECLARE L_CR_ID NUMBER; L_ATTRIBUTE_REC AR_RECEIPT_API_PUB.ATTRIBUTE_REC_TYPE; L_GLOBAL_ATT_REC AR_R ...

随机推荐

  1. php -- 显示当前时间

    默认为UTC ----- 002-time.php ----- <!DOCTYPE html> <html> <head> <meta http-equiv= ...

  2. Go的方法集

    方法集定义了接口的接受规则. package main import "fmt" type notifier interface { notify() } type user st ...

  3. solr(四) : springboot 整合 solr

    前言: solr服务器搭起来, 数据导入之后, 就该应用到项目中去了. 那在项目中, 该怎么整合和应用solr呢? 接下来, 就来整合和应用solr 一. 整合 1. 引入jar包 <prope ...

  4. slf4j 作用及logback概述

    为什么要使用slf4j 现实场景: 我们自己的系统中使用了logback这个日志系统 我们的系统使用了A.jar,A.jar中使用的日志系统为log4j 我们的系统又使用了B.jar,B.jar中使用 ...

  5. 常用的Maven 插件

    Maven本质上是一个插件框架,它的核心并不执行任何具体的构建任务,所有这些任务都交给插件来完成. 例如编译源代码是由maven- compiler-plugin完成的.进一步说,每个任务对应了一个插 ...

  6. php中判断mysql查询返回结果集是否为空

    我是php的新手,对于判断 $query = "SELECT * FROM driver; $result = mysql_query($query) or die(mysql_error( ...

  7. JVM内存结构(转)

    所有的Java开发人员可能会遇到这样的困惑?我该为堆内存设置多大空间呢?OutOfMemoryError的异常到底涉及到运行时数据的哪块区域?该怎么解决呢?其实如果你经常解决服务器性能问题,那么这些问 ...

  8. 前端自动构建工具Gulp入门

    基于nodeJs:通过不同插件能自动完成一系列动作,比如压缩js/css/img.解析模版标签.解析less等: 一.安装gulp 安装nodeJs 打开Node.js command prompt ...

  9. Silverlight 查询DataGrid 中匹配项 ,后台改变选中行颜色

    需求:根据关键字(参会人号码或名称)查找参会人,在datagird 中高亮显示 界面:我在界面上增加了一个文本框和按钮,进行查找操作 操作说明: 根据关键字进行搜索:输入关键字 点击查找,如果找到 以 ...

  10. C# Claims-based(基于声明)的认证

    本文是通过验证与网上资料整合的,请读者注意. 目录: 1. 什么是Claims-based认证 2.进一步理解Claims-based认证 3.Claims-based的简单demo 1. 什么是Cl ...