Business Intelligence – Oracle

Archive for February 29th, 2008

Oracle BI EE – Varying Columns Dynamically using Session Variables

Posted by Venkatakrishnan J on February 29, 2008

If you had gone through my blog entry here, you would have known how to go about dynamically varying the columns using presentation variables and dashboard prompts. But say you have a scenario wherein you are integrating BI EE into an external application using GO URL, then the above procedure would not be valid since presentation variables would work only from dashboards. Now, lets look at an approach wherein we can dynamically vary the columns in a report using GO URL. This approach is based on yesterday’s blog entry here. Our idea is to create a simple report wherein there would be 2 columns. One column will be dynamic based on what we pass in the GO URL and the other would be static. In our example, we shall be making use of a session variable called DSN while shall be initialized to some value through an init block. Now, lets create a simple report with 2 columns. One column would have the below formula


So, basically what this does is, it chooses the columns based on the value of the session variable. The value of the session variable will be varied from the GO URL.

The other column will be a static column (Sales).



Now, save this report. Ensure that you have added the Session variable to the instanceconfig.xml using the procedure here. Now, if you issue the below GO URLs the report columns will change automatically.





The disadvantage of this approach is that you will be losing the default hierarchy drills. You can still use Navigate to achieve the drills though.

Posted in All Posts, OBI EE Plus | 1 Comment »