Forum Discussion
Dynamic Parameter Setup to Denodo in Power BI
- 1 year ago
Hi Vasanthrk,
Thank you for reaching out to the Microsoft fabric community forum. Also thanks Akash_Varuna, for his inputs on this thread. I have identified few workarounds that may help resolve the issue.
Based on your description, it appears you are developing a reusable Power BI template that connects to Denodo via ODBC, and you aim to make the connection dynamic by using parameters for the server, database, etc. Although this approach works well for file-based sources, you are encountering difficulties when trying to implement the same technique with Denodo over ODBC.
Note: Power BI does not support directly parameterizing ODBC connection strings through the standard UI in a dynamic way. As a result, you're unable to switch servers or databases dynamically when connecting to Denodo using parameters especially within reusable .pbit templates.
Create Parameters: Go to Home > Manage Parameters > New Parameter, and create: ServerName (e.g., denodo-dev.company.com). Port (e.g., 9999). DatabaseName (e.g., my_db)
Create a Dynamic Connection String: In Power Query Editor, add a Blank Query and paste the following code:let ServerName = ServerNameParameter, Port = PortParameter, DatabaseName = DatabaseNameParameter, ConnectionString = "Driver={DenodoODBCDriver};" & "Server=" & ServerName & ";" & "Port=" & Number.ToText(Port) & ";" & "Database=" & DatabaseName & ";" & "UID=your_username;" & "PWD=your_password;", Source = Odbc.DataSource(ConnectionString, [HierarchicalNavigation=true]) in Source
Replace your_username and your_password as needed. For production purposes, it is advisable to store credentials securely using Power BI Gateway or Windows Credential Manager instead of embedding them.
Navigate to Your Denodo Tables: After connecting, expand the source to locate your tables. Apply any necessary transformations.
Save as a Template: Go to File > Export > Power BI Template (.pbit). Upon opening, users will be prompted to enter the parameters, such as those for different environments like Dev, Test, or Prod.
If this post helps, then please give us ‘Kudos’ and consider Accept it as a solution to help the other members find it more quickly.Thank you for using Microsoft Community Forum.
Hi Vasanthrk,
Thank you for reaching out to the Microsoft fabric community forum. Also thanks Akash_Varuna, for his inputs on this thread. I have identified few workarounds that may help resolve the issue.
Based on your description, it appears you are developing a reusable Power BI template that connects to Denodo via ODBC, and you aim to make the connection dynamic by using parameters for the server, database, etc. Although this approach works well for file-based sources, you are encountering difficulties when trying to implement the same technique with Denodo over ODBC.
Note: Power BI does not support directly parameterizing ODBC connection strings through the standard UI in a dynamic way. As a result, you're unable to switch servers or databases dynamically when connecting to Denodo using parameters especially within reusable .pbit templates.
Create Parameters: Go to Home > Manage Parameters > New Parameter, and create: ServerName (e.g., denodo-dev.company.com). Port (e.g., 9999). DatabaseName (e.g., my_db)
Create a Dynamic Connection String: In Power Query Editor, add a Blank Query and paste the following code:
let
ServerName = ServerNameParameter,
Port = PortParameter,
DatabaseName = DatabaseNameParameter,
ConnectionString =
"Driver={DenodoODBCDriver};" &
"Server=" & ServerName & ";" &
"Port=" & Number.ToText(Port) & ";" &
"Database=" & DatabaseName & ";" &
"UID=your_username;" &
"PWD=your_password;",
Source = Odbc.DataSource(ConnectionString, [HierarchicalNavigation=true])
in
Source
Replace your_username and your_password as needed. For production purposes, it is advisable to store credentials securely using Power BI Gateway or Windows Credential Manager instead of embedding them.
Navigate to Your Denodo Tables: After connecting, expand the source to locate your tables. Apply any necessary transformations.
Save as a Template: Go to File > Export > Power BI Template (.pbit). Upon opening, users will be prompted to enter the parameters, such as those for different environments like Dev, Test, or Prod.
If this post helps, then please give us ‘Kudos’ and consider Accept it as a solution to help the other members find it more quickly.
Thank you for using Microsoft Community Forum.
- v-kpoloju-msft1 year agoCommunity Support
Hi Vasanthrk,
May I ask if you have resolved this issue? If so, please mark the helpful reply and accept it as the solution. This will be helpful for other community members who have similar problems to solve it faster.
Thank you.
- v-kpoloju-msft1 year agoCommunity Support
Hi Vasanthrk,
I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions. If my response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.
Thank you.- v-kpoloju-msft1 year agoCommunity Support
Hi Vasanthrk,
I hope this information is helpful. Please let me know if you have any further questions or if you'd like to discuss this further. If this answers your question, please Accept it as a solution and give it a 'Kudos' so others can find it easily.
Thank you.