Tutorial: Running Custom RIs


The Developer allows users to create and run their own Repository Instructions. Instructions are useful to query a repository about component properties, recent modifications. Repository Instructions can be used to manipulate applications components (the Developer itself use RIs to create and modify components). While you might want to start with something simple, there is no limit to what can be performed with Repository Instructions.

NOTE. Repository Instructions have full read / write access to your application. A misbehaving RI could delete or corrupt application components. Always make sure you have backups of your application source prior to running Repository Instructions.

Create a Repository Instruction

To create a Repository Instruction, always start with a sample and modify it to your requirements. Use an text or XML editor to make modifications and save the results to a file.

The myview.xml example is provided in your local installation or http://localhost/bpxml/myview.xml (or click here for a new copy). This RI will query the repository for application components modified for the current Job Id.

For information on the RI capabilities see the Repository Instruction Reference or if you are using a smart XML editor, use the RI XML Schema to help write valid instructions.

NOTE. Many links referred to in this document are available in your local installation in [installdir]/web/bpxml. This directory is normally available as a virtual directory as http://localhost/bpxml.

Running the RI

To run the RI use the pulldown option "Tools / Run RI..." and enter the name of the request file. Provide a file name to store the reply.

Normally is it best to validate the RI against the internal XML Schema's in the Developer. Press the "Validate" button.

If the instruction is valid, press "Run" to execute the RI. When done press Open Reply to with the results in a browser window.

Transforming the Reply

In raw XML the reply might suit your needs. If you want a more readable or printable result, apply an XSL Transformation to produce another XML or HTML format. There is a myview.xsl example transformation in your local installation bpxml directory (or here for a copy).

In the RI popup, specify the name of .xsl file and a file to place the results of the transformation. Press "Run" again and then Open Results. In the result file name specify .htm or .xml extension to allow the browser to display the results accordingly.

Example RIs

This example will retrieve a list of functions where the name matches "E*" or "W*" and the process "Rebuild".


This example will retrieve the properties of all functions where the name matches "E*" and the process "Rebuild".


This example will replace a function and a process.


This example will delete a data dictionary named "EmpNo" and all screens where the name matches "gen*".