I am migrating reports from SSRS to QuickSight. We have multiple database of different clients. I don’t want to create same copy of Dashboard for different client database. When we design Quicksight dashbord, It asks for a datasource first. How can we pass datasource from .Net code to make Datasource dynamic. Any help is appreciated.
Hello @pgohil1, if you have the datasets created within each datasource, you could replace the dataset and publish the dashboard using the Analysis Template depending on the user that is accessing it (if you are embedding the dashboards).
Here is the documentation for CreateTemplate in the QuickSight SDK. With the analysis template, you can swap the datasets programmatically as long as the dataset field names match. Then you can update the existing analysis with the template and republish to the dashboard. That is going to be the best way to accomplish this without publishing multiple dashboards.
Let me know if you have any questions!
Hello @pgohil1, I wanted to check in since we have not heard back from you. Do you have any follow-up questions regarding my previous response? With a little more information, I can help guide you further.
If we do not hear back from you in 3 days, I will archive this topic. Thank you!
Hi Dylan,
Thanks for you response. Really appreciate it.
I am still not clear on the template part. I made analysis for one database. The same analysis needs to be replicated in other databases but the datasource is hardcoded as first step. Do you have some more details on creating these templates and how to call these template from .Net code?
Hello @pgohil1, I can try to explain the process a little more clearly. I am not familiar with running these API calls in .NET (rather I have utilized the CLI, Python, and JavaScript), but the functionalities are available.
Basically, you want to create a template of the analysis. The dataset that you have linked to the analysis doesn’t particularly matter. Then, if you want to update the datasets that are linked to the analysis (and subsequent dashboard), then you can either create a new analysis or update the existing analysis with the template. There, you are able to replace the previous dataset arns with the new dataset arns that you want to link to the analysis. Here is the SDK documentation for UpdateAnalysis:
It accepts the template ARN and dataset ARNs separately. The documentation I linked is for the QuickSight APIs. All of these API calls are available within the .NET SDK. I can link that documentation as well:
Does that make a little more sense?
Thank you for all your help. I will try to implement this. Really appreciate it.
Hi,
I am trying to create a template.
aws quicksight create-template
–aws-account-id
–template-id
–source-entity SourceAnalysis=arn:aws:quicksight:
–name
I am getting this error. Can someone please help.
Parameter validation failed:
Invalid type for parameter SourceEntity.SourceAnalysis, value: arn:aws:quicksight:us-east-1 type: <class ‘str’>, valid types: <class ‘dict’>