Home / OIM / Using Custom Java in BI Publisher Reports

Using Custom Java in BI Publisher Reports

Using Custom Java in BI Publisher Reports

BI Publisher is a powerful tool for reporting. As the out-of-the-box report(s) solution available for Oracle Identity Management products, BI Publisher provides a ton of useful reporting capabilities. It is sometimes necessary to create custom reports that are tailored for specific needs and we have a great tool for adding functionality: your own custom Java code. Using this method, you can do some cool things like complicated logic, transformation, and more…

Here’s how it’s done.

Create Custom Java Class

Start by creating your Java class (using Eclipse* for example) and create a JAR file. The functionality can be as simple or complex as needed.

Example, IDMWORKS recently deployed a custom report with Java code that accessed an LDAP field for includsion into the report. Our customized code included functionality for querying an LDAP server and returning the resulting value as a string.

Copy JAR File To Weblogic Domain Lib

In order to leverage the custom JAR file in BI Publisher reports, it is necessary to add the JAR file to the Weblogic server class path.

The easiest way to do this is to copy the JAR file to the $DOMAIN_HOME/lib directory. This will automatically add the JAR file to your server classpath (you will need to restart for this addition to take effect).

Create Report Template 

Next, you will want to create a report template using the template builder for Microsoft Word. When you identify the field which should include your custom Java method, you need to insert a custom field with the following:

  • Note 1 – You can define the custom namespace in a field at the top of the RTF template to reference it in more than one place.
  • Note 2 – The input parameter for your custom method can refer to a field name from the result set. You could apply a transformation to a field pulled from the database.

Now simply create your report in BI Publisher, upload your template, choose your data source, and that’s all there it to it. This is a really powerful and flexible tool for your custom reports and as you can see it’s pretty easy to use it.

 

Happy coding!

 

Questions, comments or concerns? Feel free to reach out to us below or at IDMWORKS

Check Also

Logging into & setting up iManager

Logging into iManager is a little deceptive if trying to do it for the first …

Taking Control of Your Oracle Identity Manager Scheduler

According to Oracle’s sizing guide for Oracle Identity Manager (OIM) 10g in a large deployment …