I hit the same exact error as in here: 'sqlcmd' is not recognized at CreateShardApplicationDatabaseServerLoginSqlCmd step

I tried the suggestion there to install the 2 modules required. The environment path was also present when I check.

Still it does not work.

The only reason I can think of is the version of modules required for Windows Server 2016 might be different.

Please share your ideas if you have similar issues

Thanks.

Hiep

I think I hit the same error before. You can try the following solutions to see whether it works for your case.

  1. Install SQL Server Data Tool
  2. If you are using SQL Server 2017, then you will need to modify your deployment script as per this article.
  • Thanks for your reply. However the solution is much simpler than that. I think the Powershell script read information from cache or something. After I close the Powershell window and open it again, the install script runs fine :) – Kurt Le Dec 7 at 8:25
  • Had this issue myself a while back - and closing Powershell and reopening it after installing those helped me solve it too. Glad it got resolved :) – Justin Bradley Dec 10 at 23:47

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.