Categories
- All Categories
- 15 Oracle Analytics Sharing Center
- 15 Oracle Analytics Lounge
- 208 Oracle Analytics News
- 41 Oracle Analytics Videos
- 15.7K Oracle Analytics Forums
- 6.1K Oracle Analytics Idea Labs
- Oracle Analytics User Groups
- 76 Oracle Analytics Trainings
- 14 Oracle Analytics Data Visualizations Challenge
- Find Partners
- For Partners
Business Unit prompt not working when TopN is applied in OTBI

Hi All
I have a margin analysis where I added Business Unit as a prompt so the user can switch between BUs.
But when I apply a TopN filter, the Business Unit prompt is not responding — it automatically selects the default BU and I’m not able to choose any other BU from the prompt.
Has anyone faced this issue or know how to fix it?
Best Answer
-
Hi @skhan,
The problem arises because the TopN filter is applied before the prompt value is processed, causing the report to default to a specific Business Unit and ignore user selections.
Try the below:- Use a Presentation Variable in the Filter:
Instead of hardcoding the TopN filter, use a presentation variable tied to the Business Unit prompt:
sql
FILTER("Revenue"."Amount" USING "Business Unit"."Name" = '@{P_BU}')
Then apply the TopN logic within a pivot or table view, not directly in the analysis filter.2. Apply TopN in the View, Not in the Criteria:
Remove the TopN filter from the Criteria tab.
In the Table or Pivot View, go to Edit Table Properties → Data Sorting → Row Count and set the TopN there.
This allows the prompt to apply first, and the TopN to be evaluated afterward.3. Use a Subquery or Filtered Analysis:
Create a filtered analysis that uses the prompt value and returns only the relevant Business Unit data.
Then apply TopN logic in a second analysis or dashboard section.Thanks,
Riyaz Ali0