You are on page 1of 12

Introduction The Oracle Payments team has only delivered BIP cheque printing templates in RTF format.

If you try and set the output type to TEXT for these, the resulting file will be full of pesky control characters and other such symbols. ETEXT templates were originally developed for creating fixed position or delimited format Text files for EFT and EDI transmission (cheque). WHENEVER you need to generate a fixed or delimited text file from an XML Publisher data source, think 'ETEXT'. You define the structure, format and logic of your TEXT file in RTF format (i.e. using Microsoft Word) and when this is applied against your XML data file, the appropriate TEXT file is produced. Many standalone check print solutions integrated with Oracle E-business suite require only a fixed position text file of check data. In order to fulfill this requirement, we have to: 1)- Define the structure of the fixed position Check file required by the third party software. 2)- Understand the XML file created from APPS 3)- Build an ETEXT template according to the structure defined in point 1 and based upon the XML file from point 2. 4) - Set up Oracle Payments to use our custom ETEXT template for Check printing. OK - lets look at each of these points:

1) - Define the structure of the Check file required: Before I start to build my template or write any code, I like to map the required file structure completely i.e. define what records appear on each line, their relative positions, length and any padding that is required.

In R12 when you made payment Format Payment Instruction request will run automatically. In the Log file of this request we will get the XML data which is generated by default. See the below screen shot. Copy the XML data and save with .XML extension. This XML file structure is constant for all payments. so based on this XML file our check or EFT design will start.

Now we have the XML data in our Hand. So lets start our Check designing. In this First we have to know how many lines will fit in the check(x=180(Rows) y=66(Columns)). For this Calculation in This Folder I am Attaching a Sample template with the Name LINES_IN_CHECK.RTF Attach this template to your Format payment Instruction format. Then do the Payment. The output will be like below.

Print this output on the check so that we can analyze how many lines are printing in the check. Now define what records appear on each line, their relative positions, length and any padding that is required. I recommend creating a table with at least the following information: - Line Num: the line number in the text file - Field Name: the name of the attribute in the file - Position From: the position number where the attribute value starts on the line - Field Length: the length of the attribute - Padding character: any padding character if the attribute length is less than the field length - XML File Source: the source tag value from the Payments Disbursement XML file - Default Value: the default value of the field. For this here I am attaching Sample RTF with above attributes. CHECK_DATA_LINENUM.rtf Attach this Template to Format Payment Instruction Format. The output will be like below. Print this on the check.

Note: Install Oracle BI Publisher Desktop. If you needs any help in


developing the E-text Template go to Oracle BI Publisher Desktop->BI Publisher user guide (PDF).And find the topic:Creating an e-text Template.

Note: After Developing the E-text template we can test the output with the help of Template viewer..
From the Windows Start menu, click on : All Programs, Oracle BI Publisher Desktop, Template Viewer:

Once the - select template - change

Template Viewer is open: your working directory i.e. the folder containing your eText and preview XML data the output format to eText :

and then click on the button 'Start Processing' to view the generated text file with

2)- Understand the XML file created from APPS There are 4 main levels to the file. These are: Top Level: Outbound Payment Instruction This is the top level of the XML File and there is one Outbound Payment Instruction per Payment process request. Level 2: Outbound Payment: This is the Payment Level i.e. an individual cheque or BACS payment amount to a supplier. There can be multiple Outbound Payments per Outbound Payment Instruction. Level 3: Document Payable: Details the documents (i.e. invoices) being paid. There can be multiple Document Payable tags per Outbound Payment Level 4: Document Payable Line: This level details the invoice line. There can be multiple Document Payable Line tags per Document Payable.

Additional XML tags can be added at each of these 4 levels by coding different PL/SQL functions in IBY_FD_EXTRACT_EXT_PUB package. The following table lists the functions you need to modify to add additional tags to each level of the XML file: IBY_FD_EXTRACT_EXT_PUB Function Example of Parameter XML File Level To Modify Usage SELECT * FROM iby_pay_instructions_a ll Get_Ins_Ext_Agg(p_payment_instruc OutboundPaymentInstr WHERE tion_id IN NUMBER) uction payment_instruction_id = p_payment_instruction_ id; SELECT * FROM iby_payments_all ipa WHERE ipa.payment_id = p_payment_id;

OutboundPayment

Get_Pmt_Ext_Agg(p_payment_id IN NUMBER)

DocumentPayable

SELECT * FROM iby_docs_payable_all Get_Doc_Ext_Agg(p_document_payabl dp WHERE e_id IN NUMBER) dp.document_payable_id = P_document_payable_id; Get_Docline_Ext_Agg(p_document_pa yable_id IN NUMBER, p_line_number IN NUMBER)

DocumentPayableLine

SELECT * FROM iby_pay_service_reques ts WHERE PaymentProcessProfil Get_Ppr_Ext_Agg(p_payment_service payment_service_reques e _request_id IN NUMBER) t_id = p_payment_service_requ est_id;

Note: Please find the IBY_FD_EXTRACT_EXT_PUB.pck in this folder which we have


implemented custom attributes (Amount units, adding Blank lines, Supllier, Invoice attribute etc) for BLIL Check printing. This package will add the custom attributes to the XML file during the format payment processing

3)- Build an ETEXT template according to the structure defined in point 1 and based upon the XML file from point 2. ETEXT templates are used to generate Fixed or delimited text files from BI Publisher. All commands are created within a RTF document (i.e. MS Word). ETEXT templates start with global commands and then have line commands for each line required in the file and field commands for each individual field within the line. The ETEXT template structure is:

- GLOBAL FILE COMMANDS --- NEW LINE COMMANDS ------ FIELDS WITHIN LINE COMMANDS --- NEW LINE COMMANDS ------ FIELDS WITHIN LINE COMMANDS --- NEW LINE COMMANDS ------ FIELDS WITHIN LINE COMMANDS

GLOBAL FILE COMMANDS: These are the commands and parameters that affect the whole text file being produced. This includes: - TEMPLATE TYPE: the type of text file being created i.e. Fixed or delimited - OUTPUT CHARACTER SET: the appropriate character set - NEW RECORD CHARACTER: the character used to mark the end of a line and the start of a new line i.e. carriage return <TEMPLATE TYPE> FIXED_POSITION_BASED

<OUTPUT CHARACTER SET> <NEW RECORD CHARACTER>

iso-8859-1 Carriage Return

NEW LINE COMMANDS: These commands affect the line as it written to the text file i.e. - LEVEL: the corresponding parent tag or level within the XML file. - DISPLAY CONDITION: any conditions that must be met before the line is written - NEW RECORD: the addition of a new line marker to the file

<NEW RECORD>

BLANK LINE 14

FIELDS WITHIN LINE COMMANDS: These commands add each individual field to the current line. They include: - POSITION: the starting position of the field on the line(for Fixed position files) - LENGTH: the length of the field - PAD:

any required padding of the field - DATA: the source of the field i.e. a default value or an element from the XML file

<LEVEL> <POSITION> <NEW RECORD> 1 7 <LENGTH>

OutboundPayment <FORMAT> <PAD> <DATA> <COMMENTS>

BLANK LINE 1 Alpha L, L, R, PAY: Label

15

Alpha

Label

23

57

Alpha

Payee/Name

Payee Name

<NEW RECORD> 7 15

BLANK LINE 14 Alpha L, 14 Label

<NEW RECORD> 1 7

BLANK LINE 15 Alpha L, L, R, ADDRESS: Label

15

Alpha

Address Label

23

57

Alpha

Payee/Address/Add ressLine1

Address Line1

NOTE: For greater explanation, check out Chapter 9 of the BIP User Guide. NOTE: BLIL_CREDPAY_CHECK.rtf this is the Final template working well in BLIL. So please alter this template as per your Check format.

Registration Process 1 Go to Payables manager->Oracle Payments setup page

Payables manager->Oracle Payments setup page->XML publisher format template

2 Payables manager->Oracle Payments setup page->formats Create the format and attach the template.

After this Creating Profile Payables manager->Oracle Payments setup page->PaymentProcessProfiles

You might also like