cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
shkhar
Microsoft
Microsoft

support for powershell scripting in power BI

Is there any support for powershell scripting in power BI

1 ACCEPTED SOLUTION
Greg_Deckler
Super User
Super User

5 REPLIES 5
matthew_davis02
Frequent Visitor

Is there any options for developers who would like to access the PowerBI API (specifically updating datasource) via AWS Linux-Based lambda?

 

param
New Member

Hi Everyone,

I was searching for some Live online help for Powershell.
However i didn't find any suitable online live group

So, i thought to create a Skype Group.
Here we can help each other to solve any Powershell issue or puzzle.

Please join me on https://join.skype.com/yY056Inw1A8q

Let's help each other.

Regards,
Param

Greg_Deckler
Super User
Super User

https://sethcoussens.com/2016/01/19/automation-series-1-part-2-powershell-and-power-bi/


@ me in replies or I'll lose your thread!!!
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Learn Power BI 2nd Edition

 I was able to publish power bi report using PowerBi Import power shell CLI command

But suddenly it has stopped publishing and it give me below error .. please can someone help me how it can be resolved

 

powerbi ] Importing C:\Users\pawadet\Documents\PowerBi_reports\ETL_Card_1_Transaction_Failures.pbix to workspace: ddde32f2-a5f9-4027-b7c8-14c7c26989a3
[ powerbi ] File uploaded successfully
[ powerbi ] Import ID: 83a1090f-02e5-4255-953e-58f25eb0b052
powerbi : C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\lib\cli-import.js:69
At line:1 char:1
+ powerbi import -c $CollectionName -w $WSguid -k $accesKeyPBI -n $Card ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (C:\Users\pawade...li-import.js:69:String) [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError

cli_1.Cli.print('Checking import state: %s', importResult.importState);
^

TypeError: Cannot read property 'importState' of undefined
at C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\lib\cli-import.js:69:70
at C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\powerbi-api\lib\autorest\operations\imports.js:416:14
at retryCallback
(C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\ms-rest\lib\filters\systemErrorRetryPolicyFilter.js:85:9)
at retryCallback
(C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\ms-rest\lib\filters\exponentialRetryPolicyFilter.js:135:9)
at handleRedirect (C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\ms-rest\lib\filters\redirectFilter.js:36:9)
at Request._callback (C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\ms-rest\lib\requestPipeline.js:126:16)
at Request.self.callback (C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\request\request.js:187:22)
at emitTwo (events.js:106:13)
at Request.emit (events.js:191:7)
at Request.<anonymous> (C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\request\request.js:1044:10)

I was able to publish report using PowerBi Import CLI (power shell)command earlier

but suddenly this command is giving me below error

No idea why this is coming now..

powerbi ] Importing C:\Users\pawadet\Documents\PowerBi_reports\ETL_Card_1_Transaction_Failures.pbix to workspace: ddde32f2-a5f9-4027-b7c8-14c7c26989a3
[ powerbi ] File uploaded successfully
[ powerbi ] Import ID: 83a1090f-02e5-4255-953e-58f25eb0b052
powerbi : C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\lib\cli-import.js:69
At line:1 char:1
+ powerbi import -c $CollectionName -w $WSguid -k $accesKeyPBI -n $Card ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (C:\Users\pawade...li-import.js:69:String) [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError

cli_1.Cli.print('Checking import state: %s', importResult.importState);
^

TypeError: Cannot read property 'importState' of undefined
at C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\lib\cli-import.js:69:70
at C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\powerbi-api\lib\autorest\operations\imports.js:416:14
at retryCallback
(C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\ms-rest\lib\filters\systemErrorRetryPolicyFilter.js:85:9)
at retryCallback
(C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\ms-rest\lib\filters\exponentialRetryPolicyFilter.js:135:9)
at handleRedirect (C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\ms-rest\lib\filters\redirectFilter.js:36:9)
at Request._callback (C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\ms-rest\lib\requestPipeline.js:126:16)
at Request.self.callback (C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\request\request.js:187:22)
at emitTwo (events.js:106:13)
at Request.emit (events.js:191:7)
at Request.<anonymous> (C:\Users\pawadet\AppData\Roaming\npm\node_modules\powerbi-cli\node_modules\request\request.js:1044:10)

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Power BI Dev Camp Session 23 768x460.jpg

Check it Out!

Mark your calendars and join us on Thursday, June 30 at 11a PDT for a great session with Ted Pattison!

Top Solution Authors