|
如何查询AP Invoice抛砖到GL的日记账
1. xla_transaction_entities是具体业务和SLA关系表
2. gl_import_references是SLA和GL的关系表
常用SQL
select * from ap_invoices_all where invoice_num = 'BXJ20120904_001'
select * from ap_invoice_lines_all where invoice_id = 2977123
select accounting_event_id from ap_invoice_distributions_all where invoice_id = 2977123
select entity_id from xla. xla_events where event_id = 21380679
select source_id_int_1, transaction_number from xla.xla_transaction_entities where entity_id = 21028756
select * from xla. xla_ae_headers where event_id = 21380679
select * from xla. xla_ae_lines where ae_header_id in ( 121331026, 121331041)
select * from xla. xla_distribution_links where ae_header_id in ( 121331026, 121331041)
select je_batch_id, je_header_id , gl_sl_link_id , gl_sl_link_table , reference_5 entity_id , reference_6 accounting_event_id , reference_7 ae_header_id from gl_import_references where gl_sl_link_id = 246342532 select * from gl_je_lines where je_header_id = 2720705 and gl_sl_link_id = 246342532
select * from gl_je_batches where je_batch_id = 2694595
select * from gl_je_headers whereje_batch_id = 2694595
|