Powershell script gets stuck, doesn't exit when called from batch file

前端 未结 10 647
不知归路
不知归路 2020-12-24 11:08

I have a PowerShell script that connects to a web site, and parses its returned data (It\'s about importing a previously uploaded SQL file into the web site\'s data base). T

10条回答
  •  悲哀的现实
    2020-12-24 11:52

    Try adding the /WAIT parameter. It will keep the .bat waiting until the PowerShell script completes.

    START /WAIT powershell "& "C:\data\etc\run_import_script.ps1"
    

提交回复
热议问题