Invoice Data XSD

The structure contained in the invoice data XSD file is used to create the invoice XML document, which is used by Crystal Reports to generate the invoice report.

MineMarket includes a default InvoiceDataSet.xsd file; however, an invoice data XML script can be set up to add new fields or to modify existing ones. See Invoice Data XML Scripts.

The XSD structure is defined by the core XML document, which can be extended but must not break the existing structure.

For example, a customer might require the invoice report to display tiered contract charges, which the core XML document does not provide as part of the layout. The XSD can be extended to display tiered charges. The code to populate tiered contract charges must also be added to the invoice XML data script.

There can be only one XSD per customer site. The recommended naming format is <CustomerName>InvoiceDataSet.xsd.

XSD File Path Property

The file path property of the XSD should be set to the MineMarket application folder; for example, C:\Program Files\Datamine\MineMarket 5.5.

To set the path:

  1. Place the XSD in the MineMarket application folder.
  2. In the Current Data Source screen of Crystal Reports Designer:
    1. Expand the report » NewDataSet » Properties node.
    2. Set the File Path property.

Important: Avoid hard-coding the server location in the file path. The Database Login screen displays if the MineMarket Client cannot find the applicable invoice XSD file for an invoice report. No combination of Login ID and Password will work on this screen.

It is a known issue that the default invoice data XSD has a hard coded path of C:\dev\BulkTrak\Source\BulkTrak.Component\GUI\Reports\InvoiceDataSet.xsd, which must be replicated if using that XSD for demo purposes.

XSD Updates

If you modify the XSD after it has been set in the Crystal Reports Designer, the database (that is, the XSD) has to be ‘verified’ so that Crystal Reports can detect the changes.

To verify the XSD:

  1. With the report active in the Design tab in Crystal Reports Designer, on the Database menu, select Verify Database.
  2. Follow the prompts as required. For more information, see https://help.sap.com/docs/SAP_CRYSTAL_REPORTS/dfc124becfa845ffa91b1e717b20e3ec/474bebec6e041014910aba7db0e91070.html.

If a new complex type has been added to the XSD, the connection itself may need to be refreshed for changes to be detected.

To refresh the connection:

  1. In the Database Expert screen of Crystal Reports Designer:
    1. Select the Data tab.
    2. In the Available Data Sources tree, right-click the NewDataSet node and select Refresh from the menu.