Script for Creating a Credit Memo (AR)

DECLARE l_return_status varchar2(1); p_count NUMBER; l_msg_count number; l_msg_data varchar2(2000); l_batch_id number; l_cnt number := 0; l_batch_source_rec ar_invoice_api_pub.batch_source_rec_type; l_trx_header_tbl ar_invoice_api_pub.trx_header_tbl_type; l_trx_lines_tbl ar_invoice_api_pub.trx_line_tbl_type; l_trx_dist_tbl ar_invoice_api_pub.trx_dist_tbl_type; l_trx_salescredits_tbl ar_invoice_api_pub.trx_salescredits_tbl_type; l_customer_trx_id number; cnt number; v_context varchar2(100); Cursor list_errors IS Select TRX_HEADER_ID, ERROR_MESSAGE from ar_trx_errors_gt; /* Cursor to get the user id information based on the input user name / CURSOR … Read more Script for Creating a Credit Memo (AR)