301: SELECT
302: 222,
303: ZTH.entity_code,
304: ZTH.event_class_code,
305: 'AR_TRX_LINES_GT', -- interface_entity_code
306: TLG.trx_line_id, -- interface_entity_line_id
307: TL.customer_trx_id,
308: 'LINE',
309: TL.customer_trx_line_id,
373: TL.description
374: FROM
375: RA_CUSTOMER_TRX_LINES TL,
376: RA_CUSTOMER_TRX T,
377: AR_TRX_LINES_GT TLG,
378: ZX_TRX_HEADERS_GT ZTH,
379: HZ_CUST_ACCOUNTS STCA,
380: HZ_CUST_ACCT_SITES STPS,
381: HZ_CUST_SITE_USES STCSU,
490: ZTH.internal_organization_id,
491: 222,
492: ZTH.entity_code,
493: ZTH.event_class_code,
494: 'AR_TRX_LINES_GT',
495: GTL.trx_line_id, -- tax line in AR_GT table
496: ZTH.trx_id,
497: GTL.link_to_cust_trx_line_id,
498: GTL.tax_regime_code,
509: GTL.tax_exempt_number,
510: 'N', -- no lines in LINK table
511: GTL.trx_line_id -- 4698302
512: FROM
513: AR_TRX_LINES_GT GTL, -- tax lines
514: ZX_TRX_HEADERS_GT ZTH
515: WHERE
516: GTL.line_type = 'TAX'
517: AND GTL.customer_trx_id = ZTH.trx_id;
711: mtax.interface_line_attribute15,
712: plin.org_id
713: FROM ZX_LINES zxt,
714: RA_CUSTOMER_TRX_LINES plin,
715: AR_TRX_LINES_GT mtax
716: WHERE plin.request_id = p_request_id
717: AND zxt.application_id = 222
718: AND zxt.entity_code = 'TRANSACTIONS'
719: /* 7166862 */
809: mtax.interface_line_attribute15,
810: plin.org_id
811: FROM ZX_LINES zxt,
812: RA_CUSTOMER_TRX_LINES plin,
813: AR_TRX_LINES_GT mtax
814: WHERE plin.request_id = p_request_id
815: AND zxt.application_id = 222
816: AND zxt.entity_code = 'TRANSACTIONS'
817: /* 7166862 */
886: il.trx_header_id,
887: il.trx_line_id,
888: zxe.message_text
889: FROM ZX_VALIDATION_ERRORS_GT zxe,
890: AR_TRX_LINES_GT il
891: WHERE nvl(zxe.interface_tax_line_id, zxe.interface_line_id) =
892: il.trx_line_id;
893:
894: l_trx_validation_errors := SQL%ROWCOUNT;
904: il.trx_line_id,
905: zxe.message_text
906: FROM ZX_ERRORS_GT zxe,
907: AR_TRX_HEADER_GT it,
908: AR_TRX_LINES_GT il
909: WHERE zxe.trx_id = it.customer_trx_id
910: AND NVL(zxe.trx_line_id, -99) =
911: il.customer_trx_line_id (+);
912: