Create a Business Document for billing and delivery

The sample company’s delivery and billing data is processed by an application that also accepts XML files as input. This application performs two tasks:

  • Composing and printing the invoices that are also used by the employees of the company as delivery notes
  • Appending the invoice information to the accounting files of the company

The input document for this software is very similar to the order that came from the web server, except that some extra amounts are computed:

  • The order processing and delivery fees, that the customer is charged with, this is 5% of the order total
  • The fees paid back to the partner restaurant: this is computed from the previous fees using a rate that is related to the partner
  • The grand total of the invoice that includes extra customer charges

Partner fees come from another XML document in which partner names are linked with the rate:

<?xml version="1.0" encoding="ISO-8859-1"?>



<name>Bombay Club Restaurant</name>




<name>Old Ebbitt Grill</name>








Again, repeat the procedure for creating an XML Business Document, this time name it BD_billingDelivery to match the structure of this output XML document as shown in the following graphic:

Structure of the output XML document

This Business Document is very similar to the BD_orderFromWeb Business Document. The differences are in the nodes highlighted in the previous graphic: orderid, amount, charges, partner_fees, and total. Each of these nodes holds values that your DML Block computes from the nodes of the BD_orderFromWeb Business Document.

Related Links