Created
April 21, 2022 18:49
-
-
Save zachrenwick/2cb5975d5dfce7ac2c9794575b631817 to your computer and use it in GitHub Desktop.
Power BI Powershell Command to Copy Report and Rebind to New Dataset
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Update nuget | |
Install-PackageProvider -Name NuGet -Force | |
# Install power bi cmdlts if not already installed (may take a little bit of time) | |
Install-Module -Name MicrosoftPowerBIMgmt -Force | |
# Connect to service | |
Connect-PowerBIServiceAccount | |
#Make a copy of DEV report but rebind it to Prod dataset | |
#Docs here: https://docs.microsoft.com/en-us/powershell/module/microsoftpowerbimgmt.reports/copy-powerbireport?view=powerbi-ps | |
Copy-PowerBIReport ` | |
-Name "00000000-0000-0000-0000-000000000000" ` | |
-Id "00000000-0000-0000-0000-000000000000" ` | |
-WorkspaceId "00000000-0000-0000-0000-000000000000" ` | |
-TargetWorkspaceId "00000000-0000-0000-0000-000000000000" ` | |
-TargetDatasetId "00000000-0000-0000-0000-000000000000" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment