Limitação do Shell do SQL SERVER 2008

Bom pessoal, parece que tudo que é bom dura pouco hehe..Existe uma limitação no shell do sql server 2008 (SQLPS.EXE) mas podemos contornar
Eu estava tentando adicionar uns snapins da quest de controle de AD (muito show por sinal), para montar um script que varre um AD , procura por servidores e verifica se existe alguma instancia do sql server instalado …. acabei me deparando com uma limitação. O shell do sql server não se consegue adicionar snapins, o SQLPS.EXE.
Este foi o email que recebi do time do powershell do sql server .Não reparem o ingles

Yes that's what you would need to do... We try to remove this limitation next release.


-----Original Message-----
From: Laerte Poltronieri
Sent: Monday, December 01, 2008 10:13 AM
To: Michiel Wories
Subject: RE: [Spam] RE: (Michiel Wories' WebLog) : SQLPS.EXE Problems

Michel...One question..
as far i saw in your article, we use the powershell.exe and add the sql server snapins..
But i use various scripts in powershell jobs in sql server 2008...and they call sqlps.exe...
So i have to change my jobs to not use type powershell in job steps(this use sqlps.exe) and
call de powershell.exe with on type cmdexec step jobs?

Bom..intaum é uma limitação do shell do sql server. Mas tem um contorno, adicionando o snapin do sql server no powershell.exe.Cria-se um profile contendo já os sapins e executa-se os jobs do sql server em vez do type "powershell" usar o type "cmdexec"..chamando o powershell.exe script.ps1.

Colocarei um exemplo completo aqui .

I´ll be back

About Laerte Junior

Laerte Junior Laerte Junior is a SQL Server specialist and an active member of WW SQL Server and the Windows PowerShell community. He also is a huge Star Wars fan (yes, he has the Darth Vader´s Helmet with the voice changer). He has a passion for DC comics and living the simple life. "May The Force be with all of us"
This entry was posted in Powershell. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s