Modifying the Billing Invoice Extract Application Engine Program for New Layouts

If an invoice form requires information not provided in the extract tables, you can modify the extract Application Engine program, BI_IVCEXT, to extract, calculate or derive that information and place it in the extract tables. The recommended method for this type of modification is to add a section to perform the additional processing. The new procedure should only be called for invoices that require the different information. The Invoice Layout ID field can be used to select those invoices in the Billing data that require special handling. Once the system is programmed to extract the needed data into the Billing extract tables, SQR or BI Publisher form modifications might also be needed.

The following example shows a procedure, BIEVALX.SQC, that calls PROCESS-XXX-LAYOUT when an invoice with a layout id of PS_XX is processed. Include this SQC in the print process BIXXXXXX.SQR. Define the procedure PROCESS-XXX-LAYOUT in the modified SQC that is called by BIXXXXXX.SQR.

!-------------------------------------------------------------------!
! Procedure: PROCESS-LAYOUT-SPECIFIC-INFO   !
! Desc:  Select the extra processing routine according to the !
!   invoice layout.          !
!-------------------------------------------------------------------!
begin-procedure PROCESS-LAYOUT-SPECIFIC-INFO
 add 1 to #level
 move 'PROCESS-LAYOUT-SPECIFIC-INFO' to $Current-Procedure

 evaluate $InvoiceLayout
 when = 'PS_XX'    ! Example Invoice Layout
  do PROCESS-XXX-LAYOUT
  break
 when-other
  break
 end-evaluate