Forum Discussion

anshikak1's avatar
anshikak1
New Member
2 years ago

How to Enable Dynamic Ticker Filtering for API Data in Power BI?

Hi Power BI Community,

 

I'm working on a Power BI report that fetches data from several APIs provided by Financial Modeling Prep (e.g., Daily Stock Prices, Price Targets, Upgrades & Downgrades). I want to provide end-users the ability to filter the data by ticker symbols dynamically, but I'm encountering some challenges.

 

Here's what I have done so far:

1. API Data Import: Successfully imported data from the APIs in Import Mode using Power BI Desktop.
2. Parameter Creation: Created a parameter named SelectedTicker in Power Query Editor.
3. Data Fetching: Modified the API M queries to use this parameter to fetch data for the selected ticker.
4. Slicer Setup: Added a slicer to the report using a table of ticker symbols.

 

Issues:
1. Dynamic Updates: The SelectedTicker parameter in Power Query does not update dynamically based on the slicer selection made by the user.
2. Parameter Binding: Struggling with how to bind the slicer selection to the parameter so that the API calls can reflect the user-selected ticker.

 

My Question:
1. How can I dynamically update the API calls in Power BI based on the ticker symbol selected by the user in a slicer?
2. Is there a way to make the parameter update dynamically based on slicer selection?
3. What are the best practices for setting up such dynamic filtering for API data in Power BI?

 

Example:
For instance, if a user selects "AAPL" from the slicer, the report should fetch and display the latest data for AAPL from the API.

Any insights, examples, or step-by-step guidance on how to achieve this would be greatly appreciated!
Thanks in advance!

 

 

 

 

1 Reply